Estados y subestados de expedientes
Estados y subestados de expedientes
GET https://api.test.fandit.es/api/v2/forms/status-groups-list/
Petición paginada para obtener todos los posibles estados y subestados que puede tener un expediente, y poder seleccionarlos al momento de crear uno.
Cabeceras
| Authorization string | |
|---|---|
| Token de experto (Obligatorio). |
Respuesta
Object
count number
next string
previous string
results array of objects
id number
name string
status array of objects
id number
initial_state boolean
name string
template number
curl--request GET \--url 'https://api.test.fandit.es/api/v2/forms/status-groups-list/' \ import requests
url = "https://api.test.fandit.es/api/v2/forms/status-groups-list/"
response = requests.get(url)
print(response.status_code)
print(response.json())
const url = "https://api.test.fandit.es/api/v2/forms/status-groups-list/";
const options = {
method: "GET",
headers: {
}
};
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
const url: string = "https://api.test.fandit.es/api/v2/forms/status-groups-list/";
const options: RequestInit = {
method: "GET",
headers: {
}
};
const response = await fetch(url, options);
const data: any = await response.json();
console.log(data);
<?php
$url = "https://api.test.fandit.es/api/v2/forms/status-groups-list/";
$curl = curl_init($url);
curl_setopt_array($curl, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
]
]);
$response = curl_exec($curl);
curl_close($curl);
echo $response;
import java.io.IOException;
import okhttp3.*;
public class FanditApiExample {
public static void main(String[] args) throws IOException {
OkHttpClient client = new OkHttpClient();
String url = "https://api.test.fandit.es/api/v2/forms/status-groups-list/";
Request request = new Request.Builder()
.url(url)
.get()
.build();
try (Response response = client.newCall(request).execute()) {
System.out.println(response.body().string());
}
}
}
Respuesta Ejemplo de respuesta
{
"count": 6,
"next": null,
"previous": null,
"results": [
{
"id": 1,
"name": "En trámite",
"status": [
{
"id": 1,
"initial_state": true,
"name": "Pendiente de documentación",
"template": 1
},
{
"id": 2,
"initial_state": false,
"name": "En revisión",
"template": 1
}
]
},
{
"id": 2,
"name": "Concedido",
"status": [
{
"id": 3,
"initial_state": false,
"name": "Concedido - pendiente de justificación",
"template": 1
},
{
"id": 4,
"initial_state": false,
"name": "Justificado",
"template": 1
}
]
}
]
}