返回全部教程 (1) Shazam API
1. Shazam Endpoints
1.1 Recognize Song from URL
- Endpoint:
/shazam/recognize/
- Method:
GET
- Description: Recognize a song from an audio URL.
- Parameters:
url
(required): The URL of the audio file.
- Responses:
200
: Successful Response
422
: Validation Error
1.2 Recognize Song from Audio File
- Endpoint:
/shazam/recognize/
- Method:
POST
- Description: Recognize a song from an audio file.
- Request Body:
upload_file
(required): The audio file to be recognized.
- Responses:
200
: Successful Response
422
: Validation Error
1.3 Search for Artist
- Endpoint:
/shazam/search_artist/
- Method:
GET
- Description: Search for an artist.
- Parameters:
query
(required): The artist’s name or query.
limit
(optional, default: 10): Limit the number of results.
- Responses:
200
: Successful Response
422
: Validation Error
1.4 Search for Track
- Endpoint:
/shazam/search_track/
- Method:
GET
- Description: Search for a track.
- Parameters:
query
(required): The track’s name or query.
limit
(optional, default: 10): Limit the number of results.
- Responses:
200
: Successful Response
422
: Validation Error
1.5 Get Top Tracks by Country
- Endpoint:
/shazam/top_tracks_country
- Method:
GET
- Description: Get the top tracks in a specific country.
- Parameters:
country_code
(optional, default: “UZ”): Country code.
- Responses:
200
: Successful Response
422
: Validation Error