PixAI Platform
API v2 DocumentationMedia

Register an uploaded audio file

Step 3 of uploading an audio clip. The returned id is the media ID to pass in referenceAudioMediaIds.

POST
/media/audio/register

Authorization

bearerAuth
AuthorizationBearer <token>

In all requests that require authentication

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://api.pixai.art/v2/media/audio/register" \  -H "Content-Type: application/json" \  -d '{    "externalId": "3f2b8c1e-6a4d-4f6e-9b1a-2c7d5e8f9a01"  }'
{
  "id": "string",
  "fileUrl": "string",
  "duration": 0,
  "size": 0,
  "codec": "string"
}
{
  "code": "string",
  "status": 0,
  "message": "string",
  "data": {},
  "defined": true
}