Contrato histórico: POST generate-code
Contrato histórico de API. Esta página describe un contrato anterior. Los métodos, las rutas y las respuestas pueden diferir de la API vigente.
Significado histórico
Generar código
Este endpoint de la API se utiliza para generar un código
API vigente
Para desarrollar una integración nueva, consulta la referencia o guía vigente enlazada.
Ver la referencia de la API vigenteParámetros
[
{
"name": "api_version",
"in": "path",
"schema": {
"type": "string",
"default": "v400"
},
"required": true
},
{
"name": "language",
"in": "path",
"schema": {
"type": "string",
"default": "en"
},
"required": true
},
{
"name": "project",
"in": "path",
"schema": {
"type": "string",
"default": "<redacted-personal>"
},
"required": true
}
]
Cuerpo de solicitud
{
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"type",
"channel",
"size"
],
"properties": {
"type": {
"type": "integer",
"format": "int32"
},
"channel": {
"type": "integer",
"format": "int32"
},
"size": {
"type": "integer",
"format": "int32"
},
"send_data": {
"type": "string",
"format": "json"
},
"email": {
"type": "string"
},
"cellphone": {
"type": "integer",
"format": "int32"
},
"country_phone_code": {
"type": "integer",
"format": "int32"
},
"to": {
"type": "string"
}
}
}
}
}
}
Respuestas
{
"200": {
"description": "200",
"content": {
"application/json": {
"examples": {
"Result": {
"value": "{\n \"error\": false,\n \"result\": [\n \"VERIFICATION_CODE_WAS_SENT_TO\"\n ]\n}"
}
},
"schema": {
"type": "object",
"properties": {
"error": {
"type": "boolean",
"example": false,
"default": true
},
"result": {
"type": "array",
"items": {
"type": "string",
"example": "VERIFICATION_CODE_WAS_SENT_TO"
}
}
}
}
}
}
},
"400": {
"description": "400",
"content": {
"application/json": {
"examples": {
"Result": {
"value": "{\n \"error\": true,\n \"result\": [\n \"Try get code in 19 seconds.\"\n ]\n}"
}
},
"schema": {
"type": "object",
"properties": {
"error": {
"type": "boolean",
"example": true,
"default": true
},
"result": {
"type": "array",
"items": {
"type": "string",
"example": "Try get code in 19 seconds."
}
}
}
}
}
}
}
}