-
Notifications
You must be signed in to change notification settings - Fork 4
PostSong
Walter Lara edited this page Jan 16, 2025
·
20 revisions
Allows to add a new Song.
URL: /v1/songs
Method: POST
Path Parameters: None
Query Parameters: None
Headers:
Authorization: Bearer {accessToken}
Content-Type: application/json
Content:
Field | Type | Description | Requirement Type |
---|---|---|---|
title | string | Song title. | Required |
archived | boolean | Song archive indicator. Defaults to `false. | Optional |
genres | string array | Song genres. | Required |
moods | string array | Song moods. | Optional |
coverArtUrl | string | Valid URL of cover art picture file. | Optional |
lyricsUrl | string | Valid URL of song lyrics file. | Optional |
description | string | Song description. | Optional |
album | string | Song album. | Optional |
track | integer | Song track. | Optional |
language | string | Song language. | Optional |
coverRemixSample | boolean | Indicates if the Song is a Cover, Remix or Sample. | Optional |
compositionCopyrightOwner | string | Song composition copyright owner. | Optional |
compositionCopyrightYear | integer | Song composition copyright year. | Optional |
phonographicCopyrightOwner | string | Song phonographic copyright owner. | Optional |
phonographicCopyrightYear | integer | Song phonographic copyright year. | Optional |
parentalAdvisory | string | Song parental advisory. | Optional |
barcodeType | string | Song barcode type. Valid values are: Upc and Ean. | Optional |
barcodeNumber | string | Song barcode number. | Optional |
isrc | string | International Standard Recording Code (ISRC). | Optional |
iswc | string | International Standard Musical Work Code (ISWC). | Optional |
ipis | string array | Interested Party Information (IPIS) Numbers. | Optional |
releaseDate | string | Song release date (ISO-8601 format) | Optional |
Content example:
{
"title": "Blinding Lights",
"genres": ["Synthwave", "Synthpop"],
"moods": ["Cool", "Upbeat"],
"coverArtUrl": "https://www.example.com/bindinglights/cover.png",
"lyricsUrl": "https://www.example.com/bindinglights/lyrics.txt",
"description": "Song by The Weeknd",
"compositionCopyrightOwner": "© The Weeknd",
"compositionCopyrightYear": 2023
}
Code: 200 OK
Headers:
Content-Type: application/json
Content:
Field | Type | Description | Condition |
---|---|---|---|
songId | string | UUID of the added Song. | Always |
Content example:
{
"songId": "7bd2862f-8deb-4814-8943-156d9dab80dd"
}
Code: 400 BAD REQUEST
Condition: If a mandatory content field is missing.
Headers:
Content-Type: application/json
Content example:
{
"code": 400,
"description": "Bad Request",
"cause": "missing title"
}
Code: 401 UNAUTHORIZED
Condition: If {accessToken}
is invalid or expired.