Term Type (Unused)
Get Term Type
GET - /termtype/pk_term_type /
Description
Description
Captura as informações detalhadas de um Tipo de Etapa específico.
Name | In | Type | Default | Nullable | Description |
---|---|---|---|---|---|
Authorization |
header | string | None | No | Obtained in Login |
pk_term_type |
path variables | string | None | No | Obtained in List Term Type |
Response Body
200
{
"results": {
"pk_term_type": 1,
"name": "bimestre"
}
}
Schema
{
"results": {
"pk_term_type": integer,
"name": string
}
}
400
{
"detail": "Não foi possivel encontrar este TermType.",
"render": 1
}
Schema
{
"detail": string,
"render": integer
}
500
{
"detail": "Problemas ao visualizar TermType",
"error": "descrição do erro interno"
}
Schema
{
"detail": string,
"error": string
}
List Term Type
GET - /termtype/list/
Description
Description
Lista todos os Tipo de Etapa cadastrados no sistema
Name | In | Type | Default | Nullable | Description |
---|---|---|---|---|---|
Authorization |
header | string | None | No | Obtained in Login |
page |
query param | string | 1 | Yes | |
page_size |
query param | string | 30 | Yes |
Response Body
200
{
"navigation": {
"next": "http://alppi/sys/api/v1/termtype/list/?page=3&page_size=20", // link para proxima pagina
"previous": "http://alppi/sys/api/v1/termtype/list/?page=1&page_size=10" // link para pagina anterior
},
"next": 3, // numero da proxima pagina
"previous": 1, // numero na pagina anterior
"count": 1, // quantidade encontrata
"results": [
{
"pk_term_type": 1,
"name": "bimestre"
}
]
}
Schema
{
"navigation": {
"next": string,
"previous": string
},
"next": integer,
"previous": integer,
"count": integer,
"results": array of objects {
"pk_term_type": integer,
"name": string
}
}
500
{
"detail": "Problemas ao listar todos os TermType.",
"error": "descrição do erro interno"
}
Schema
{
"detail": string,
"error": string
}
Create Term Type
POST - /termtype/create/
Description
Description
Rota para criação de um novo Tipo de Etapa.
Name | In | Type | Default | Nullable | Description |
---|---|---|---|---|---|
Authorization |
header | string | None | No | Obtained in Login |
fk_subject_area |
body | integer | None | Yes | Obtained in List Subject Area |
Request Body
{
"name": "create"
}
Body Schema
{
"name": string
}
Response Body
200
{
"results": {
"pk_term_type": 4,
"name": "Create"
}
}
Schema
{
"results": {
"pk_term_type": integer,
"name": string
}
}
400
{
"detail": {
"name": [
"This field is required."
]
},
"render": 0
}
Schema
{
"detail": object,
"render": integer
}
500
{
"detail": "Problemas ao cadastrar TermType",
"error": "descrição do erro interno"
}
Schema
{
"detail": string,
"error": string
}
Update Term Type
PUT - /termtype/pk_term_type /update/
Description
Description
Rota para a atualização dos dados de um Tipo de Etapa.
Name | In | Type | Default | Nullable | Description |
---|---|---|---|---|---|
Authorization |
header | string | None | No | Obtained in Login |
pk_term_type |
path variables | string | None | No | Obtained in List Term Type |
Request Body
{
"name": "update"
}
Schema
{
"name": string
}
Response Body
200
{
"results": {
"pk_term_type": 4,
"name": "Update"
}
}
Schema
{
"results": {
"pk_term_type": integer,
"name": string
}
}
400
{
"detail": "Não foi possivel encontrar este TermType.",
"render": 1
}
Schema
{
"detail": string,
"render": integer
}
{
"detail": {
"name": [
"This field is required."
]
},
"render": 0
}
Schema
{
"detail": object,
"render": integer
}
500
{
"detail": "Problemas ao editar TermType",
"error": "descrição do erro interno"
}
Schema
{
"detail": string,
"error": string
}
Delete Term Type
DELL - /termtype/pk_term_type /delete/
Description
Description
Rota para excluir um Tipo de Etapa.
Name | In | Type | Default | Nullable | Description |
---|---|---|---|---|---|
Authorization |
header | string | None | No | Obtained in Login |
pk_term_type |
path variables | string | None | No | Obtained in List Term Type |
Response Body
204 No Content
400
{
"detail": "Não foi possivel encontrar este TermType."
}
Schema
{
"detail": string,
"render": integer
}
500
{
"detail": "Problemas ao deletar TermType",
"error": "descrição do erro interno"
}
Schema
{
"detail": string,
"error": string
}