Code Monkey home page Code Monkey logo

vitrine-social's Issues

Atualizar uma Necessidade

Necessidade [/need/{id}]

Atualizar Need [PUT]

  • Parameters

    • id (number) - Id da necessidade
  • Request Atualizar

    • Headers

        Accept: application/json
        Content-Type: application/json
        Authorization: JWT
      
    • Attributes (NeedPayload)

  • Response 204 (application/json)

  • Response 400 (application/json)

    • Attributes (Error)

Remover uma Imagem da Organização

Remover imagem [/organization/{id}/image/{image_id}]

Remover imagem [DELETE]

  • Parameters

    • id (number) - Id da ONG
    • image_id (number) - Id da imagem
  • Request

    • Headers

        Accept: application/json
        Content-Type: application/json
        Authorization: JWT
      
  • Response 204

  • Response 400 (application/json)

    • Attributes (Error)

Retornar Perfil da Organização

Organização [/organization/{id}]

Perfil da ONG [GET]

  • Parameters

    • id (number) - Id da ONG
  • Response 200 (application/json)

    • Attributes (DetailedOrganization)
  • Response 404 (application/json)

    • Attributes (Error)

Pesquisa de Necessidades

Search [/search?text={text}&category={categories}&org={org}&page={page}]

Fazer busca [GET]

  • Parameters

    • text: texto a ser pesquisado (string, optional) - Texto a ser pesquidado
    • categories: 1,2,3 (string, optional) - Ids das categorias
    • org: 1 (number, optional) - Id da entidade para filtrar
    • page: 1 (number, optional) - Paginação (vai trazer sempre 10 por página)
  • Request Busca das necessidades

    • Headers

        Accept: application/json
        Content-Type: application/json
      
  • Response 200 (application/json)

    • Attributes (array[BaseNeed])

Tela de Confirmação de Cadastro Organização

Criar uma tela que deve receber um token JWT pela URL e solicitar que a Organização informe uma senha para acessar o sistema, depois disso a tela enviar a nova senha para o backend deve redirecionar para a tela de login.

Parar de receber notificações sobre Organização

Unsubscribe [/organization/{id}/unsubscribe/{email}]

Parar de receber notificações [GET]

  • Parameters

    • id (number) - Id da ONG
    • email (string) - E-mail
  • Response 204 (application/json)

  • Response 404 (application/json)

    • Attributes (Error)

Adicionar uma imagem a Organização

Upload [/organization/{id}/upload]

Fazer upload [POST]

  • Parameters

    • id (number) - Id da ONG
  • Request Upload de um arquivo

    • Headers

        Accept: application/json
        Content-Type: application/json
        Authorization: JWT
      
    • Attributes (UploadFile)

  • Response 201 (application/json)

    • Attributes (Created)
  • Response 400 (application/json)

    • Attributes (Error)

Atualizar Senha

POST /v1/auth/update-password
Example URI: POST http://api.vitrine.dev:8001/v1/v1/auth/update-password

Request Atualizar SenhaHide

Headers

Accept: application/json
Content-Type: application/json
Authorization: JWT

Body

{
  "currentPassword": "123",
  "newPassword": "1234"
}

Schema

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "currentPassword": {
      "type": "string",
      "description": "Senha Atual"
    },
    "newPassword": {
      "type": "string",
      "description": "Nova Senha"
    }
  }
}

Response 200

Response 400

Headers

Content-Type: application/json

Body

{
  "code": 400,
  "message": "Hello, world!"
}

Schema

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "code": {
      "type": "number",
      "description": "Status code"
    },
    "message": {
      "type": "string",
      "description": "Mensagem do status"
    }
  }
}

Implementação do storage para arquivos

What is the objective?

Implementar storage para subir arquivos no S3.

Be careful on ...

  • Rever handler DeleteOrganizationImage para remover o arquivo do storage também.

Remover imagem de uma Necessidade

Remover imagem [/need/{id}/image/{image_id}]

Remover imagem [DELETE]

  • Parameters

    • id (number) - Id da necessidade
    • image_id (number) - Id da imagem
  • Request

    • Headers

        Accept: application/json
        Content-Type: application/json
        Authorization: JWT
      
  • Response 204

  • Response 400 (application/json)

    • Attributes (Error)

Retornar Detalhes de uma Necessidade

Necessidade [/need/{id}]

Dados da necessidade [GET]

  • Parameters

    • id (number) - Id da necessidade
  • Response 200 (application/json)

    • Attributes (Need)
  • Response 404 (application/json)

    • Attributes (Error)

Se inscrever para notificações da Organização

Subscribe [/organization/{id}/subscribe]

Receber notificações [POST]

  • Parameters

    • id (number) - Id da ONG
  • Request

    • Attributes
      • email (string) - E-mail
      • name (string) - Nome
      • phone (string) - Telefone
  • Response 204 (application/json)

  • Response 404 (application/json)

    • Attributes (Error)

Responder a uma necessidade [POST]

requires #45

Response [/need/{id}/response]

Responder a uma necessidade [POST]

  • Parameters

    • id (number) - Id da necessidade
  • Request

    • Attributes
      • email (string) - E-mail
      • name (string) - Nome
      • phone (string) - Telefone
      • address (string) - Endereço
      • message (string) - Mensagem enviada para a ONG
  • Response 204 (application/json)

  • Response 404 (application/json)

    • Attributes (Error)

Adicionar Imagem a uma Necessidade

Upload [/need/{id}/upload]

Fazer upload [POST]

  • Parameters

    • id (number) - Id da necessidade
  • Request Upload de um arquivo

    • Headers

        Accept: application/json
        Content-Type: application/json
        Authorization: JWT
      
    • Attributes (UploadFile)

  • Response 201 (application/json)

    • Attributes (Created)
  • Response 400 (application/json)

    • Attributes (Error)

Login

Login [/auth/login]

Realizar login [POST]

  • Request Login

    • Headers
      Accept: application/json
      Content-Type: application/json
    • Attributes (Login)
  • Response 200 (application/json)

    • Attributes
      • organization (BaseOrganization)
      • token: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiYWRtaW4iOnRydWV9.TJVA95OrM7E2cBab30RMHrHDcEfxjoYZgeFONFh7HgQ (string)
  • Response 404 (application/json)

    • Attributes (Error)

Logout

Logout [/auth/logout]

Realizar logout [POST]

  • Request Logout

    • Headers
      Accept: application/json
      Content-Type: application/json
      Authorization: JWT
  • Response 204

Atualizar Organização

Organização [/organization/{id}]

Atualizar ONG [PUT]

  • Parameters

    • id (number) - Id da ONG
  • Request Atualizar

    • Headers
      Accept: application/json
      Content-Type: application/json
      Authorization: JWT
    • Attributes (DetailedOrganization)
  • Response 204 (application/json)

  • Response 400 (application/json)

    • Attributes (Error)

Criar uma Necessidade

Criar [/need]

Criar Need [POST]

  • Request Criar

    • Headers

        Accept: application/json
        Content-Type: application/json
        Authorization: JWT
      
    • Attributes (NeedPayload)

  • Response 201 (application/json)

    • Attributes (Created)
  • Response 400 (application/json)

    • Attributes (Error)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.