1295 lines
29 KiB
YAML
1295 lines
29 KiB
YAML
basePath: /
|
|
definitions:
|
|
anos_formaturas.AnoFormaturaResponse:
|
|
properties:
|
|
ano_semestre:
|
|
type: string
|
|
id:
|
|
type: string
|
|
type: object
|
|
anos_formaturas.CreateAnoFormaturaRequest:
|
|
properties:
|
|
ano_semestre:
|
|
example: "2029.1"
|
|
type: string
|
|
required:
|
|
- ano_semestre
|
|
type: object
|
|
auth.authRequest:
|
|
properties:
|
|
email:
|
|
type: string
|
|
senha:
|
|
minLength: 6
|
|
type: string
|
|
required:
|
|
- email
|
|
- senha
|
|
type: object
|
|
auth.loginResponse:
|
|
properties:
|
|
access_token:
|
|
type: string
|
|
expires_at:
|
|
type: string
|
|
profissional: {}
|
|
user:
|
|
$ref: '#/definitions/auth.userResponse'
|
|
type: object
|
|
auth.userResponse:
|
|
properties:
|
|
email:
|
|
type: string
|
|
id:
|
|
type: string
|
|
role:
|
|
type: string
|
|
type: object
|
|
cursos.CreateCursoRequest:
|
|
properties:
|
|
nome:
|
|
type: string
|
|
required:
|
|
- nome
|
|
type: object
|
|
cursos.CursoResponse:
|
|
properties:
|
|
id:
|
|
type: string
|
|
nome:
|
|
type: string
|
|
type: object
|
|
empresas.CreateEmpresaRequest:
|
|
properties:
|
|
nome:
|
|
type: string
|
|
required:
|
|
- nome
|
|
type: object
|
|
empresas.EmpresaResponse:
|
|
properties:
|
|
id:
|
|
type: string
|
|
nome:
|
|
type: string
|
|
type: object
|
|
funcoes.CreateFuncaoRequest:
|
|
properties:
|
|
nome:
|
|
type: string
|
|
required:
|
|
- nome
|
|
type: object
|
|
funcoes.FuncaoResponse:
|
|
properties:
|
|
id:
|
|
type: string
|
|
nome:
|
|
type: string
|
|
type: object
|
|
profissionais.CreateProfissionalInput:
|
|
properties:
|
|
agencia:
|
|
type: string
|
|
banco:
|
|
type: string
|
|
carro_disponivel:
|
|
type: boolean
|
|
cidade:
|
|
type: string
|
|
conta_pix:
|
|
type: string
|
|
cpf_cnpj_titular:
|
|
type: string
|
|
desempenho_evento:
|
|
type: integer
|
|
disp_horario:
|
|
type: integer
|
|
educacao_simpatia:
|
|
type: integer
|
|
endereco:
|
|
type: string
|
|
equipamentos:
|
|
type: string
|
|
extra_por_equipamento:
|
|
type: boolean
|
|
funcao_profissional_id:
|
|
type: string
|
|
media:
|
|
type: number
|
|
nome:
|
|
type: string
|
|
observacao:
|
|
type: string
|
|
qtd_estudio:
|
|
type: integer
|
|
qual_tec:
|
|
type: integer
|
|
tabela_free:
|
|
type: string
|
|
tem_estudio:
|
|
type: boolean
|
|
tipo_cartao:
|
|
type: string
|
|
uf:
|
|
type: string
|
|
whatsapp:
|
|
type: string
|
|
type: object
|
|
profissionais.ProfissionalResponse:
|
|
properties:
|
|
agencia:
|
|
type: string
|
|
banco:
|
|
type: string
|
|
carro_disponivel:
|
|
type: boolean
|
|
cidade:
|
|
type: string
|
|
conta_pix:
|
|
type: string
|
|
cpf_cnpj_titular:
|
|
type: string
|
|
desempenho_evento:
|
|
type: integer
|
|
disp_horario:
|
|
type: integer
|
|
educacao_simpatia:
|
|
type: integer
|
|
endereco:
|
|
type: string
|
|
equipamentos:
|
|
type: string
|
|
extra_por_equipamento:
|
|
type: boolean
|
|
funcao_profissional:
|
|
description: Now returns name from join
|
|
type: string
|
|
funcao_profissional_id:
|
|
type: string
|
|
id:
|
|
type: string
|
|
media:
|
|
type: number
|
|
nome:
|
|
type: string
|
|
observacao:
|
|
type: string
|
|
qtd_estudio:
|
|
type: integer
|
|
qual_tec:
|
|
type: integer
|
|
tabela_free:
|
|
type: string
|
|
tem_estudio:
|
|
type: boolean
|
|
tipo_cartao:
|
|
type: string
|
|
uf:
|
|
type: string
|
|
usuario_id:
|
|
type: string
|
|
whatsapp:
|
|
type: string
|
|
type: object
|
|
profissionais.UpdateProfissionalInput:
|
|
properties:
|
|
agencia:
|
|
type: string
|
|
banco:
|
|
type: string
|
|
carro_disponivel:
|
|
type: boolean
|
|
cidade:
|
|
type: string
|
|
conta_pix:
|
|
type: string
|
|
cpf_cnpj_titular:
|
|
type: string
|
|
desempenho_evento:
|
|
type: integer
|
|
disp_horario:
|
|
type: integer
|
|
educacao_simpatia:
|
|
type: integer
|
|
endereco:
|
|
type: string
|
|
equipamentos:
|
|
type: string
|
|
extra_por_equipamento:
|
|
type: boolean
|
|
funcao_profissional_id:
|
|
type: string
|
|
media:
|
|
type: number
|
|
nome:
|
|
type: string
|
|
observacao:
|
|
type: string
|
|
qtd_estudio:
|
|
type: integer
|
|
qual_tec:
|
|
type: integer
|
|
tabela_free:
|
|
type: string
|
|
tem_estudio:
|
|
type: boolean
|
|
tipo_cartao:
|
|
type: string
|
|
uf:
|
|
type: string
|
|
whatsapp:
|
|
type: string
|
|
type: object
|
|
tipos_eventos.CreateEventoRequest:
|
|
properties:
|
|
nome:
|
|
type: string
|
|
required:
|
|
- nome
|
|
type: object
|
|
tipos_eventos.EventoResponse:
|
|
properties:
|
|
id:
|
|
type: string
|
|
nome:
|
|
type: string
|
|
precos:
|
|
items:
|
|
$ref: '#/definitions/tipos_eventos.PrecoResponse'
|
|
type: array
|
|
type: object
|
|
tipos_eventos.PrecoResponse:
|
|
properties:
|
|
funcao_nome:
|
|
type: string
|
|
funcao_profissional_id:
|
|
type: string
|
|
id:
|
|
type: string
|
|
tipo_evento_id:
|
|
type: string
|
|
valor:
|
|
type: number
|
|
type: object
|
|
tipos_eventos.PriceInput:
|
|
properties:
|
|
funcao_profissional_id:
|
|
type: string
|
|
tipo_evento_id:
|
|
type: string
|
|
valor:
|
|
type: number
|
|
type: object
|
|
tipos_servicos.CreateTipoServicoRequest:
|
|
properties:
|
|
nome:
|
|
type: string
|
|
required:
|
|
- nome
|
|
type: object
|
|
tipos_servicos.TipoServicoResponse:
|
|
properties:
|
|
id:
|
|
type: string
|
|
nome:
|
|
type: string
|
|
type: object
|
|
host: localhost:8080
|
|
info:
|
|
contact:
|
|
email: support@swagger.io
|
|
name: API Support
|
|
url: http://www.swagger.io/support
|
|
description: Backend authentication service for Photum.
|
|
license:
|
|
name: Apache 2.0
|
|
url: http://www.apache.org/licenses/LICENSE-2.0.html
|
|
termsOfService: http://swagger.io/terms/
|
|
title: Photum Backend API
|
|
version: "1.0"
|
|
paths:
|
|
/api/anos-formaturas:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/anos_formaturas.AnoFormaturaResponse'
|
|
type: array
|
|
security:
|
|
- BearerAuth: []
|
|
summary: List all graduation years
|
|
tags:
|
|
- anos_formaturas
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Ano Semestre
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/anos_formaturas.CreateAnoFormaturaRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
schema:
|
|
$ref: '#/definitions/anos_formaturas.AnoFormaturaResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"409":
|
|
description: Conflict
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Create a new graduation year
|
|
tags:
|
|
- anos_formaturas
|
|
/api/anos-formaturas/{id}:
|
|
delete:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"204":
|
|
description: No Content
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Delete a graduation year
|
|
tags:
|
|
- anos_formaturas
|
|
put:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
- description: Ano Semestre
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/anos_formaturas.CreateAnoFormaturaRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/anos_formaturas.AnoFormaturaResponse'
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Update a graduation year
|
|
tags:
|
|
- anos_formaturas
|
|
/api/cursos:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/cursos.CursoResponse'
|
|
type: array
|
|
security:
|
|
- BearerAuth: []
|
|
summary: List all courses
|
|
tags:
|
|
- cursos
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Curso Name
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/cursos.CreateCursoRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
schema:
|
|
$ref: '#/definitions/cursos.CursoResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"409":
|
|
description: Conflict
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Create a new course
|
|
tags:
|
|
- cursos
|
|
/api/cursos/{id}:
|
|
delete:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Curso ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"204":
|
|
description: No Content
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Delete a course
|
|
tags:
|
|
- cursos
|
|
put:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Curso ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
- description: Curso Name
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/cursos.CreateCursoRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/cursos.CursoResponse'
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Update a course
|
|
tags:
|
|
- cursos
|
|
/api/empresas:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/empresas.EmpresaResponse'
|
|
type: array
|
|
security:
|
|
- BearerAuth: []
|
|
summary: List all companies
|
|
tags:
|
|
- empresas
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Empresa Name
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/empresas.CreateEmpresaRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
schema:
|
|
$ref: '#/definitions/empresas.EmpresaResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"409":
|
|
description: Conflict
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Create a new company
|
|
tags:
|
|
- empresas
|
|
/api/empresas/{id}:
|
|
delete:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Empresa ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"204":
|
|
description: No Content
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Delete a company
|
|
tags:
|
|
- empresas
|
|
put:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Empresa ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
- description: Empresa Name
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/empresas.CreateEmpresaRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/empresas.EmpresaResponse'
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Update a company
|
|
tags:
|
|
- empresas
|
|
/api/funcoes:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
description: List all professional functions
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/funcoes.FuncaoResponse'
|
|
type: array
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
summary: List functions
|
|
tags:
|
|
- funcoes
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
description: Create a new professional function
|
|
parameters:
|
|
- description: Create Function Request
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/funcoes.CreateFuncaoRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
schema:
|
|
$ref: '#/definitions/funcoes.FuncaoResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"409":
|
|
description: Conflict
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Create a new function
|
|
tags:
|
|
- funcoes
|
|
/api/funcoes/{id}:
|
|
delete:
|
|
consumes:
|
|
- application/json
|
|
description: Delete a professional function by ID
|
|
parameters:
|
|
- description: Function ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Delete function
|
|
tags:
|
|
- funcoes
|
|
put:
|
|
consumes:
|
|
- application/json
|
|
description: Update a professional function by ID
|
|
parameters:
|
|
- description: Function ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
- description: Update Function Request
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/funcoes.CreateFuncaoRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/funcoes.FuncaoResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"409":
|
|
description: Conflict
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Update function
|
|
tags:
|
|
- funcoes
|
|
/api/profissionais:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
description: List all profissionais
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/profissionais.ProfissionalResponse'
|
|
type: array
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: List profissionais
|
|
tags:
|
|
- profissionais
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
description: Create a new profissional record
|
|
parameters:
|
|
- description: Create Profissional Request
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/profissionais.CreateProfissionalInput'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
schema:
|
|
$ref: '#/definitions/profissionais.ProfissionalResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Create a new profissional
|
|
tags:
|
|
- profissionais
|
|
/api/profissionais/{id}:
|
|
delete:
|
|
consumes:
|
|
- application/json
|
|
description: Delete a profissional by ID
|
|
parameters:
|
|
- description: Profissional ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Delete profissional
|
|
tags:
|
|
- profissionais
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
description: Get a profissional by ID
|
|
parameters:
|
|
- description: Profissional ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/profissionais.ProfissionalResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"404":
|
|
description: Not Found
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Get profissional by ID
|
|
tags:
|
|
- profissionais
|
|
put:
|
|
consumes:
|
|
- application/json
|
|
description: Update a profissional by ID
|
|
parameters:
|
|
- description: Profissional ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
- description: Update Profissional Request
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/profissionais.UpdateProfissionalInput'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/profissionais.ProfissionalResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Update profissional
|
|
tags:
|
|
- profissionais
|
|
/api/tipos-eventos:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/tipos_eventos.EventoResponse'
|
|
type: array
|
|
security:
|
|
- BearerAuth: []
|
|
summary: List all event types
|
|
tags:
|
|
- tipos_eventos
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Nome
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/tipos_eventos.CreateEventoRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
schema:
|
|
$ref: '#/definitions/tipos_eventos.EventoResponse'
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Create a new event type
|
|
tags:
|
|
- tipos_eventos
|
|
/api/tipos-eventos/{id}:
|
|
delete:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Event ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"204":
|
|
description: No Content
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Delete an event type
|
|
tags:
|
|
- tipos_eventos
|
|
put:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Event ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
- description: Event Data
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/tipos_eventos.CreateEventoRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/tipos_eventos.EventoResponse'
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Update an event type
|
|
tags:
|
|
- tipos_eventos
|
|
/api/tipos-eventos/{id}/precos:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Event ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/tipos_eventos.PrecoResponse'
|
|
type: array
|
|
security:
|
|
- BearerAuth: []
|
|
summary: List prices for an event
|
|
tags:
|
|
- tipos_eventos
|
|
/api/tipos-eventos/precos:
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Price Input
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/tipos_eventos.PriceInput'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Set price for an event function
|
|
tags:
|
|
- tipos_eventos
|
|
/api/tipos-servicos:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/tipos_servicos.TipoServicoResponse'
|
|
type: array
|
|
security:
|
|
- BearerAuth: []
|
|
summary: List all service types
|
|
tags:
|
|
- tipos_servicos
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: Nome
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/tipos_servicos.CreateTipoServicoRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
schema:
|
|
$ref: '#/definitions/tipos_servicos.TipoServicoResponse'
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"409":
|
|
description: Conflict
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Create a new service type
|
|
tags:
|
|
- tipos_servicos
|
|
/api/tipos-servicos/{id}:
|
|
delete:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"204":
|
|
description: No Content
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Delete a service type
|
|
tags:
|
|
- tipos_servicos
|
|
put:
|
|
consumes:
|
|
- application/json
|
|
parameters:
|
|
- description: ID
|
|
in: path
|
|
name: id
|
|
required: true
|
|
type: string
|
|
- description: Nome
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/tipos_servicos.CreateTipoServicoRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/tipos_servicos.TipoServicoResponse'
|
|
security:
|
|
- BearerAuth: []
|
|
summary: Update a service type
|
|
tags:
|
|
- tipos_servicos
|
|
/auth/login:
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
description: Login with email and password
|
|
parameters:
|
|
- description: Login Request
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/auth.authRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
$ref: '#/definitions/auth.loginResponse'
|
|
"401":
|
|
description: Unauthorized
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
summary: Login
|
|
tags:
|
|
- auth
|
|
/auth/logout:
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
description: Revoke refresh token and clear cookie
|
|
parameters:
|
|
- description: Refresh Token
|
|
in: body
|
|
name: refresh_token
|
|
schema:
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
summary: Logout user
|
|
tags:
|
|
- auth
|
|
/auth/refresh:
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
description: Get a new access token using a valid refresh token
|
|
parameters:
|
|
- description: Refresh Token
|
|
in: body
|
|
name: refresh_token
|
|
schema:
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
additionalProperties: true
|
|
type: object
|
|
"401":
|
|
description: Unauthorized
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
summary: Refresh access token
|
|
tags:
|
|
- auth
|
|
/auth/register:
|
|
post:
|
|
consumes:
|
|
- application/json
|
|
description: Register a new user (defaults to 'profissional' role) with email
|
|
and password
|
|
parameters:
|
|
- description: Register Request
|
|
in: body
|
|
name: request
|
|
required: true
|
|
schema:
|
|
$ref: '#/definitions/auth.authRequest'
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"201":
|
|
description: Created
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"400":
|
|
description: Bad Request
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
summary: Register a new user
|
|
tags:
|
|
- auth
|
|
securityDefinitions:
|
|
BearerAuth:
|
|
in: header
|
|
name: Authorization
|
|
type: apiKey
|
|
swagger: "2.0"
|