{"openapi":"3.1.0","info":{"title":"Public API","description":"This is the official public API for [Free To Use](/). The API provides open access to a large library of royalty-free music tracks made by real artists. Search, discover, stream, and download music directly – no API key required, no account needed, completely free.\n\n#### Licensing\n\nAll music available through the API is licensed under the [Free To Use License](/license). Please ensure you and your users are familiar with the terms before integrating music into your project or application. Free usage is available under specific conditions, while commercial use requires a paid license. Learn more about our licensing options [here](/faq#which-subscription-plans-and-licensing-options-do-you-offer).","short_description":"This is the official public API for Free To Use. The API provides open access to a large library of royalty-free music tracks made by real artists.","version":"3.0.0"},"servers":[{"url":"https://api.freetouse.com/v3"}],"tags":[{"name":"Music Tracks"},{"name":"Music Artists"},{"name":"Music Categories"}],"paths":{"/music/tracks/all":{"get":{"tags":["Music Tracks"],"description":"Get a list of all tracks.\n\nThe `tags`, `categories`, and `tags_categories` properties contain only the first 2 tags/categories assigned to the track. To get the full list use the [/music/tracks/{id}](#operations-Music_Tracks-get_music_tracks__id_) endpoint.","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Limit the number of results."},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Offset results."},{"name":"order","in":"query","schema":{"type":"string","enum":["release_date","views","plays","downloads","staff_order","random"],"default":"release_date"},"description":"Order results by a specific value."},{"name":"sort","in":"query","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"Sort results in either ascending or descending order."}],"responses":{"200":{"description":"Tracks List","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/PaginationResponse"}],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Track"}}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/tracks/search":{"get":{"tags":["Music Tracks"],"description":"Search tracks.\n\nThe query terms are matched against the tracks' titles, tags, categories, and artists.\n\nThe `tags`, `categories`, and `tags_categories` properties contain only the first 2 tags/categories assigned to the track. To get the full list use the [/music/tracks/{id}](#operations-Music_Tracks-get_music_tracks__id_) endpoint.","parameters":[{"name":"query","in":"query","schema":{"type":"string"},"description":"Search terms."},{"name":"limit","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Limit the number of results."},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Offset results."},{"name":"order","in":"query","schema":{"type":"string","enum":["release_date","views","plays","downloads","staff_order","random"],"default":"release_date"},"description":"Order results by a specific value."},{"name":"sort","in":"query","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"Sort results in either ascending or descending order."}],"responses":{"200":{"description":"Tracks List","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/PaginationResponse"}],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Track"}}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/tracks/{id}":{"get":{"tags":["Music Tracks"],"description":"Get a specific track by ID.\n\nThe `Track` object returned by this endpoint contains all information for the track, including a full list of tags/categories.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Track","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/Response"}],"properties":{"data":{"oneOf":[{"$ref":"#/components/schemas/Track"},{"type":"null"}]}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/tracks/{id}/related":{"get":{"tags":["Music Tracks"],"description":"Get a list of tracks related to another by its ID.\n\nThe track objects in `data` contain an extra `similarity` property that indicates how similar they are based on shared artists, tags, and categories.\n\nThe `tags`, `categories`, and `tags_categories` properties contain only the first 2 tags/categories assigned to the track. To get the full list use the [/music/tracks/{id}](#operations-Music_Tracks-get_music_tracks__id_) endpoint.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Limit the number of results."},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Offset results."},{"name":"order","in":"query","schema":{"type":"string","enum":["similarity","release_date","views","plays","downloads","staff_order","random"],"default":"similarity"},"description":"Order results by a specific value."},{"name":"sort","in":"query","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"Sort results in either ascending or descending order."}],"responses":{"200":{"description":"Tracks list","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/PaginationResponse"}],"properties":{"data":{"type":"array","items":{"allOf":[{"$ref":"#/components/schemas/Track"}],"properties":{"similarity":{"type":"integer","description":"A rank to describe how similar a track is, the higher the more similar."}}}}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/tracks/{artist}/{title}":{"get":{"tags":["Music Tracks"],"description":"Get a specific track by artist name (any of, if the track has multiple) and track title.\n\nThe `Track` object returned by this endpoint contains all information for the track, including a full list of tags/categories.","parameters":[{"name":"artist","in":"path","required":true,"schema":{"type":"string"}},{"name":"title","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Track","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/Response"}],"properties":{"data":{"oneOf":[{"$ref":"#/components/schemas/Track"},{"type":"null"}]}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/artists/all":{"get":{"tags":["Music Artists"],"description":"Get a list of all artists.","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Limit the number of results."},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Offset results."},{"name":"order","in":"query","schema":{"type":"string","enum":["name","views","random"],"default":"name"},"description":"Order results by a specific value."},{"name":"sort","in":"query","schema":{"type":"string","enum":["asc","desc"],"default":"asc"},"description":"Sort results in either ascending or descending order."}],"responses":{"200":{"description":"Artists list","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/PaginationResponse"}],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Artist"}}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/artists/{id}":{"get":{"tags":["Music Artists"],"description":"Get a specific artist by their ID.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Artist","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/Response"}],"properties":{"data":{"oneOf":[{"$ref":"#/components/schemas/Artist"},{"type":"null"}]}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/artists/{id}/tracks":{"get":{"tags":["Music Tracks"],"description":"Get tracks from a specific artist by their ID.\n\nThe `tags`, `categories`, and `tags_categories` properties contain only the first 2 tags/categories assigned to the track. To get the full list use the [/music/tracks/{id}](#operations-Music_Tracks-get_music_tracks__id_) endpoint.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Limit the number of results."},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Offset results."},{"name":"order","in":"query","schema":{"type":"string","enum":["release_date","views","plays","downloads","staff_order","random"],"default":"release_date"},"description":"Order results by a specific value."},{"name":"sort","in":"query","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"Sort results in either ascending or descending order."}],"responses":{"200":{"description":"Tracks list","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/PaginationResponse"}],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Track"}}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/categories/all":{"get":{"tags":["Music Categories"],"description":"Get a list of all categories.","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Limit the number of results."},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Offset results."},{"name":"order","in":"query","schema":{"type":"string","enum":["name","type","views","random"],"default":"name"},"description":"Order results by a specific value."},{"name":"sort","in":"query","schema":{"type":"string","enum":["asc","desc"],"default":"asc"},"description":"Sort results in either ascending or descending order."}],"responses":{"200":{"description":"Categories list","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/PaginationResponse"}],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Category"}}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/categories/{id}":{"get":{"tags":["Music Categories"],"description":"Get a specific category by its ID.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Category","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/Response"}],"properties":{"data":{"oneOf":[{"$ref":"#/components/schemas/Category"},{"type":"null"}]}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/music/categories/{id}/tracks":{"get":{"tags":["Music Tracks"],"description":"Get tracks with a specific category by its ID.\n\nThe `tags`, `categories`, and `tags_categories` properties contain only the first 2 tags/categories assigned to the track. To get the full list use the [/music/tracks/{id}](#operations-Music_Tracks-get_music_tracks__id_) endpoint.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Limit the number of results."},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"default":0},"description":"Offset results."},{"name":"order","in":"query","schema":{"type":"string","enum":["release_date","views","plays","downloads","staff_order","random"],"default":"release_date"},"description":"Order results by a specific value."},{"name":"sort","in":"query","schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"Sort results in either ascending or descending order."}],"responses":{"200":{"description":"Tracks list","content":{"application/json":{"schema":{"type":"object","allOf":[{"$ref":"#/components/schemas/PaginationResponse"}],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Track"}}}}}}},"400":{"description":"Invalid request query/body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}},"components":{"schemas":{"Response":{"type":"object","description":"Base successful response object for all endpoints.","properties":{"ok":{"type":"boolean","const":true,"description":"`true` if the request succeded, `false` otherwise."},"data":{"type":"any","description":"Data returned by the endpoint."}},"required":["ok","data"]},"PaginationResponse":{"type":"object","description":"Base successful response object for search/list endpoints.","allOf":[{"$ref":"#/components/schemas/Response"}],"properties":{"pagination":{"$ref":"#/components/schemas/Pagination"}},"required":["pagination"]},"ErrorResponse":{"type":"object","description":"Base error response object for all endpoints.","properties":{"ok":{"type":"boolean","const":false,"description":"`true` if the request succeded, `false` otherwise."},"error":{"type":"string","description":"Message describing the error if one occurred."}},"required":["ok","error"]},"Pagination":{"type":"object","description":"Pagination object for search endpoints.","properties":{"limit":{"type":["integer","null"],"description":"The limit of results per query."},"offset":{"type":"integer","description":"The offset used for the query."},"count":{"type":"integer","description":"Total number of results."}},"required":["limit","offset","count"]},"TrackArtist":{"type":"object","description":"Base representation of an `Artist` object used in `Track`.","properties":{"id":{"type":"string","format":"uuid","description":"The unique ID of the artist."},"name":{"type":"string","description":"The name of the artist."}}},"TrackCategory":{"type":"object","description":"Base representation of a `Category` object used in `Track`.","properties":{"id":{"type":"string","format":"uuid","description":"The unique ID of the category."},"name":{"type":"string","description":"The name of the category."}}},"Track":{"type":"object","description":"A music track.","properties":{"id":{"type":"string","format":"uuid","description":"The unique ID of the track."},"title":{"type":"string","description":"The title of the track."},"artists":{"type":"array","description":"The artists that created the track.","items":{"type":"array","prefixItems":[{"type":"integer","description":"The sequence number (ascending order) of the artist."},{"$ref":"#/components/schemas/TrackArtist"}]}},"genre":{"type":["string","null"],"description":"The music genre of the track, if any matches, otherwise `null`."},"lyrics":{"type":["string","null"],"description":"The language of the track's lyrics, if any, otherwise `null`."},"status":{"type":"integer","const":1,"description":"The status of the track (1 = released)."},"record_label":{"type":"string","description":"The record label to which the track is registered to."},"is_premium":{"type":"boolean","description":"`true` if the track is premium."},"duration":{"type":"number","description":"The duration of the track in seconds."},"release_date":{"type":"string","format":"date-time","description":"The release date of the track."},"waveform":{"type":"array","minItems":300,"maxItems":300,"items":{"type":"integer"},"description":"The waveform of the track, expressed in normalized \"loudness\" (0-100) along the track."},"staff_order":{"type":"integer","description":"The order (descending) of tracks in the \"Staff Picks\" group, 0 means not picked."},"views":{"type":"integer","description":"The total number of views accrued by the track since its release."},"plays":{"type":"integer","description":"The total number of plays accrued by the track since its release."},"likes":{"type":"integer","description":"The total number of likes accrued by the track since its release."},"downloads":{"type":"integer","description":"The total number of downloads accrued by the track since its release."},"update_time":{"type":"string","format":"date-time","description":"The time when the track information was last updated."},"tags":{"type":"array","items":{"type":"array","prefixItems":[{"type":"integer","description":"The sequence number (ascending order) of the tag."},{"type":"string","description":"The tag."}]},"description":"A list of string tags describing the track."},"categories":{"type":"array","items":{"type":"array","prefixItems":[{"type":"integer","description":"The sequence number (ascending order) of the tag."},{"$ref":"#/components/schemas/TrackCategory"}]},"description":"A list of categories describing the track."},"tags_categories":{"type":"array","items":{"type":"array","prefixItems":[{"type":"integer","description":"The sequence number (ascending order) of the tag/category."},{"oneOf":[{"$ref":"#/components/schemas/TrackCategory"},{"type":"string"}],"description":"The tag/category."}]},"description":"The combined list of string tags and categories describing the track."},"thumbnails":{"type":"object","properties":{"sm":{"type":"string","description":"Thumbnail in 125x125 resolution"},"md":{"type":"string","description":"Thumbnail in 500x500 resolution"},"lg":{"type":"string","description":"Thumbnail in 1000x1000 resolution"},"xl":{"type":"string","description":"Thumbnail in 3000x3000 resolution"}},"description":"The URLs to thumbnails of the track's cover art"},"files":{"type":"object","properties":{"mp3":{"type":"string","description":"Audio file in MP3 format"}},"description":"The URLs to the audio files of the track"}}},"Artist":{"type":"object","description":"A music artist.","properties":{"id":{"type":"string","format":"uuid","description":"The unique ID of the artist."},"name":{"type":"string","description":"The name of the artist."},"description":{"type":"string","description":"The description/biography of the artist."},"status":{"type":"integer","const":1,"description":"The status of the artist (1 = active)."},"views":{"type":"integer","description":"The number of views of the artist's page."},"update_time":{"type":"string","format":"date-time","description":"The time when the artist information was last updated."},"upload_date":{"type":"string","format":"date-time","description":"The time the artist information was first uploaded."},"thumbnails":{"type":"object","properties":{"sm":{"type":"string","description":"Thumbnail in 125x125 resolution"},"md":{"type":"string","description":"Thumbnail in 500x500 resolution"},"lg":{"type":"string","description":"Thumbnail in 1000x1000 resolution"},"xl":{"type":"string","description":"Thumbnail in 3000x3000 resolution"}},"description":"The URLs to thumbnails of the artist's cover art"}}},"Category":{"type":"object","description":"A music category.","properties":{"id":{"type":"string","format":"uuid","description":"The unique ID of the category."},"type":{"type":"string","description":"The name of the category type."},"type_id":{"type":"string","format":"uuid","description":"The unique ID of the category type."},"name":{"type":"string","description":"The name of the category."},"description":{"type":"string","description":"The description of the category."},"thumbnails":{"type":"object","properties":{"sm":{"type":"string","description":"Thumbnail in 125x125 resolution"},"md":{"type":"string","description":"Thumbnail in 500x500 resolution"},"lg":{"type":"string","description":"Thumbnail in 1000x1000 resolution"},"xl":{"type":"string","description":"Thumbnail in 3000x3000 resolution"}},"description":"The URLs to thumbnails of the category's cover art"}}}}}}