Skip to main content

Welcome

For SWAGGER lover, we are using the following OpenAPI specification.

Shortext Endpoints

View the OpenAPI specification file

Authentication

All API endpoints are authenticated using Bearer tokens and picked up from the specification file.
"security": [
  {
    "bearerAuth": ""
  }
]

API Response Schema

All API endpoints return code 200 with this json structure the content of the response will always be accessible by the body key
trace_id : present only when success=false. Can be used for support request
{
  "success": true,
  "message": "Request success.",
  "code": 1000,
  "body": "< CAN BE NULL, A STRING OR JSON OBJECT OR JSON ARRAY>",
  "trace_id": ""
}

Response schema for pagination

All items will be accessible from the data. To navigate to any page juste append ?page=page-number on the path
example : https://shortext.ny-corp.io/api/agent/search?page=1
{
    "current_page": 1,
    "data": [

    ],
    "first_page_url": "https://shortext.ny-corp.io/api/agent/search?page=1",
    "from": 1,
    "last_page": 1,
    "last_page_url": "https://shortext.ny-corp.io/api/agent/search?page=1",
    "next_page_url": null,
    "path": "https://shortext.ny-corp.io/api/agent/search",
    "per_page": 50,
    "prev_page_url": null,
    "to": 8,
    "total": 8
}

Response Code

CodeDescription
1The token has expired / Le token a expiré.
2The token is blacklisted / Le token est dans la liste noire.
3The token is invalid / Le token est invalide.
4The token was not found / Le token n’a pas été trouvé.
5The user associated with the token was not found / L’utilisateur associé au token n’a pas été trouvé
1000The request was successful / La requête a réussi.
1001The request failed / La requête a échoué.
1002Request validation error / Erreur de validation de la requête.
1003The request has expired / La requête a expiré.
1004Trying to insert a duplicate entry / Tentative d’insertion d’un doublon.
1005The request is not authorized / La requête n’est pas autorisée.
1006An exception occurred while processing the request / Une exception s’est produite lors du traitement de la requête.
1007The request was not found / La requête n’a pas été trouvée.
1008Incorrect JSON format in the request / Format JSON incorrect dans la requête.
1009The service is not available / Le service n’est pas disponible.
1010Emergency request / Requête d’urgence.
1100The account is not verified / Le compte n’est pas vérifié.
1101Incorrect username / Nom d’utilisateur incorrect.
1102Incorrect password / Mot de passe incorrect.
1103Incorrect credentials / Identifiants incorrects.
1104The account is verified / Le compte est vérifié.
1105The account does not exist / Le compte n’existe pas.