Errores
Todos los errores tienen el mismo formato:
{
"error": {
"code": "media_required",
"message": { "es": "…", "en": "…" },
"fix": { "es": "…", "en": "…" },
"docs_url": "https://wyroapi.vercel.app/docs/errores#media_required",
"details": { "platform": "instagram" }
}
}
missing_api_key (HTTP 401)
Falta la clave de API.
Cómo arreglarlo: Envía el header "Authorization: Bearer
The API key is missing. Send the "Authorization: Bearer
invalid_api_key (HTTP 401)
La clave de API no es válida o fue revocada.
Cómo arreglarlo: Revisa que la clave empiece con "wyro_sk_" y esté completa. Puedes crear una nueva con POST /v1/sandbox.
The API key is invalid or was revoked. Check that the key starts with "wyro_sk_" and is complete. You can create a new one with POST /v1/sandbox.
sandbox_expired (HTTP 401)
La clave de prueba venció (dura 72 horas).
Cómo arreglarlo: Crea una nueva clave de prueba con POST /v1/sandbox, o conecta una cuenta real para seguir con la misma clave.
The test key expired (it lasts 72 hours). Create a new test key with POST /v1/sandbox, or connect a real account to keep using the same key.
key_expired (HTTP 402)
El período de prueba terminó.
Cómo arreglarlo: Muéstrale al usuario el link de details.payment_url para activar un plan. La misma clave vuelve a publicar, sin reconfigurar nada.
The trial period has ended. Show the user the link in details.payment_url to activate a plan. The same key publishes again, no reconfiguration needed.
workspace_suspended (HTTP 403)
Este espacio de trabajo está suspendido.
Cómo arreglarlo: Escríbenos en https://github.com/wyroapi/wyro/issues.
This workspace is suspended. Contact us at https://github.com/wyroapi/wyro/issues.
rate_limited (HTTP 429)
Demasiadas solicitudes.
Cómo arreglarlo: Espera los segundos indicados en el header Retry-After y vuelve a intentar.
Too many requests. Wait the number of seconds in the Retry-After header and try again.
sandbox_limit (HTTP 429)
Se crearon demasiadas claves de prueba desde esta IP.
Cómo arreglarlo: Reutiliza la clave que ya tienes (dura 72 horas) o espera una hora.
Too many test keys were created from this IP. Reuse the key you already have (it lasts 72 hours) or wait an hour.
validation_error (HTTP 400)
La solicitud tiene datos inválidos.
Cómo arreglarlo: Revisa el campo indicado en details y compáralo con /openapi.json.
The request has invalid data. Check the field listed in details against /openapi.json.
platform_not_supported (HTTP 400)
Esa red social no está soportada.
Cómo arreglarlo: Usa una de: instagram, facebook, tiktok, linkedin, twitter, threads, youtube, pinterest.
That social network is not supported. Use one of: instagram, facebook, tiktok, linkedin, twitter, threads, youtube, pinterest.
no_account_for_platform (HTTP 400)
No hay una cuenta conectada para esa red.
Cómo arreglarlo: Lista las cuentas con GET /v1/accounts. Para conectar una cuenta real usa POST /v1/connect.
There is no connected account for that network. List accounts with GET /v1/accounts. To connect a real account use POST /v1/connect.
media_required (HTTP 400)
Esa red necesita una imagen o un video.
Cómo arreglarlo: Agrega "media": [{"url": "https://..."}] con una URL pública. TikTok y YouTube necesitan video.
That network needs an image or a video. Add "media": [{"url": "https://..."}] with a public URL. TikTok and YouTube need a video.
text_too_long (HTTP 400)
El texto supera el límite de la red.
Cómo arreglarlo: Acorta el texto o publica en esa red por separado. Los límites están en details.
The text exceeds the network's limit. Shorten the text or post to that network separately. Limits are in details.
account_not_found (HTTP 404)
La cuenta no existe en este espacio de trabajo.
Cómo arreglarlo: Lista las cuentas con GET /v1/accounts.
The account does not exist in this workspace. List accounts with GET /v1/accounts.
post_not_found (HTTP 404)
La publicación no existe.
Cómo arreglarlo: Revisa el id (empieza con post_). Lista las publicaciones con GET /v1/posts.
The post does not exist. Check the id (it starts with post_). List posts with GET /v1/posts.
account_disconnected (HTTP 409)
Esa cuenta está desconectada.
Cómo arreglarlo: Pídele al usuario que la vuelva a conectar con el link de details.connect_url (o POST /v1/connect).
That account is disconnected. Ask the user to reconnect it with the link in details.connect_url (or POST /v1/connect).
provider_error (HTTP 502)
La red social no aceptó la publicación en este momento.
Cómo arreglarlo: Si details.retryable es true, vuelve a intentar en un minuto. Si no, revisa el contenido (formato, duración, tamaño) y la cuenta conectada.
The social network did not accept the post right now. If details.retryable is true, retry in a minute. Otherwise check the content (format, length, size) and the connected account.
not_found (HTTP 404)
La ruta no existe.
Cómo arreglarlo: Revisa /openapi.json para ver las rutas disponibles.
The route does not exist. See /openapi.json for the available routes.
internal_error (HTTP 500)
Algo falló de nuestro lado.
Cómo arreglarlo: Vuelve a intentar en unos segundos. Si sigue pasando, abre un issue en https://github.com/wyroapi/wyro/issues con el request_id.
Something failed on our side. Try again in a few seconds. If it keeps happening, open an issue at https://github.com/wyroapi/wyro/issues with the request_id.