RelayAPI

Validate a media URL for platform compatibility

POST
/v1/tools/validate/media
AuthorizationBearer <token>

API key (rlay_live_* or rlay_test_*)

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

curl -X POST "https://example.com/v1/tools/validate/media" \  -H "Content-Type: application/json" \  -d '{    "url": "http://example.com"  }'
{  "accessible": true,  "content_type": "string",  "size": 0,  "platform_limits": {    "twitter": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "instagram": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "facebook": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "linkedin": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "tiktok": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "youtube": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "pinterest": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "reddit": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "bluesky": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "threads": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "telegram": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "snapchat": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "googlebusiness": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "whatsapp": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "mastodon": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "discord": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "sms": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "beehiiv": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "convertkit": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "mailchimp": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    },    "listmonk": {      "within_limit": true,      "max_size": 0,      "mime_type_supported": true    }  }}
{  "error": {    "code": "string",    "message": "string",    "details": {      "property1": null,      "property2": null    }  }}

Found something wrong? Help us improve this page.

Submit an Issue
Requires a GitHub account.View repo