Music API by Popnable

Πρόσβαση στα παγκόσμια charts του Popnable - τραγούδια, καλλιτέχνες, βίντεο και τάσεις για 160+ χώρες σε ένα μόνο API.

Τι μπορείτε να κάνετε;
Άμεση αυτόματη συμπλήρωση

Γρήγορα αποτελέσματα με ανοχή τυπογραφικών λαθών.

Ακριβές γεω-περίφραξη

Αναζήτηση ανά πόλη, bounding box ή ακτίνα.

Πλούσια μεταδεδομένα τοποθεσίας

Επιστρέφει αναγνωριστικά OSM, πληθυσμό, εμφανιζόμενο όνομα και άλλα.

99.9 % Διαθεσιμότητα
1239.6ms Απάντηση
10 req/s
0.01 Πιστωτικές μονάδες / αίτημα

Popnable Music API

Single endpoint that proxies Popnable API and returns normalized data for songs, trends, artists, charts and YouTube videos. The behavior is controlled by the action parameter.


POST https://api.yeb.to/v1/music/popnable

Common parameters

Παράμετρος Τύπος Απαιτ. Περιγραφή
api_key string ναι Your YEB API key.
action string ναι Selects which Popnable v2 method to call. Supported values:
search, get-trends, get-songs, get-songs-by-trend, get-artists, get-artist-by-trend, get-daily-chart, get-weekly-chart, get-monthly-chart, get-artist-chart, get-videos.

Parameters by action

action Parameter Type Required Description
search keyword string ναι Search term (song/artist). Short text (~20 chars recommended).
get-trends ids string προαιρ. Comma-separated list of trend IDs. If omitted, Popnable may return all trends (depending on provider rules).
get-songs ids string ναι Comma-separated list of song IDs.
stats string προαιρ. yes / no – include Popnable stats.
charts string προαιρ. Comma-separated list of chart types, e.g. daily,weekly.
get-songs-by-trend trend string ναι Trend ID (country/region ID in Popnable).
day string ναι Date in YYYY-MM-DD format.
stats string προαιρ. yes / no – include stats.
charts string προαιρ. Charts for the returned songs, e.g. daily,weekly,monthly.
get-artists ids string ναι Comma-separated list of artist IDs.
stats string προαιρ. yes / no – include artist stats.
charts string προαιρ. Chart type, e.g. artists.
songs string προαιρ. yes / no – include songs for each artist.
get-artist-by-trend trend string ναι Trend ID (country/region).
day string ναι Date in YYYY-MM-DD format.
stats string προαιρ. Artist stats (yes/no).
charts string προαιρ. Chart type (usually artists).
get-daily-chart trend string ναι Trend ID (country/region).
day string ναι Date for the daily chart (YYYY-MM-DD).
get-weekly-chart trend string ναι Trend ID (country/region).
day string ναι Date for the weekly chart (YYYY-MM-DD).
get-monthly-chart trend string ναι Trend ID (country/region).
day string ναι Date for the monthly chart (YYYY-MM-DD).
get-artist-chart trend string ναι Trend ID (country/region).
day string ναι Date for the artist chart (YYYY-MM-DD).
get-videos yt_codes string ναι Comma-separated list of YouTube video codes (e.g. AbCdE123).
charts string προαιρ. Chart types, e.g. daily,weekly.
dailyStats string προαιρ. yes / no – include daily breakdown stats.
day string προαιρ. Reference day (YYYY-MM-DD). If omitted, current date may be used.

Παραδείγματα αιτημάτων

1) Search by keyword (action=search)
{
  "api_key": "YOUR_KEY",
  "action" : "search",
  "keyword": "preslava"
}
2) Song details by ID (action=get-songs)
{
  "api_key": "YOUR_KEY",
  "action" : "get-songs",
  "ids"    : "123",
  "stats"  : "yes",
  "charts" : "daily,weekly"
}
3) Video stats by YouTube code (action=get-videos)
{
  "api_key"   : "YOUR_KEY",
  "action"    : "get-videos",
  "yt_codes"  : "AbCdE123",
  "charts"    : "daily,weekly",
  "dailyStats": "yes",
  "day"       : "2025-01-05"
}

Ενσωματώσεις API

curl -X POST https://api.yeb.to/v1/music/popnable \
  -H "Content-Type: application/json" \
  -d '{"api_key":"YOUR_KEY","action":"search","keyword":"preslava"}'
use Illuminate\Support\Facades\Http;

Route::post('/music-popnable-demo', function () {
    $response = Http::post('https://api.yeb.to/v1/music/popnable', [
        'api_key' => config('services.yeb.api_key'),
        'action'  => 'search',
        'keyword' => 'preslava',
    ]);

    return $response->json();
});
use Illuminate\Support\Facades\Http;

$r = Http::post('https://api.yeb.to/v1/music/popnable', [
    'api_key' => 'YOUR_KEY',
    'action'  => 'get-songs',
    'ids'     => '123',
    'stats'   => 'yes',
    'charts'  => 'daily,weekly',
]);

print_r($r->json());
fetch('https://api.yeb.to/v1/music/popnable', {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: JSON.stringify({
    api_key   : 'YOUR_KEY',
    action    : 'get-videos',
    yt_codes  : 'AbCdE123',
    charts    : 'daily,weekly',
    dailyStats: 'yes',
    day       : '2025-01-05'
  })
})
  .then(r => r.json())
  .then(console.log);
import requests, json

payload = {
    "api_key": "YOUR_KEY",
    "action" : "get-songs-by-trend",
    "trend"  : "35",
    "day"    : "2025-01-05",
    "stats"  : "yes",
    "charts" : "daily,weekly"
}

r = requests.post('https://api.yeb.to/v1/music/popnable',
                  headers={'Content-Type': 'application/json'},
                  data=json.dumps(payload))

print(r.json())

Response example

{
  "data": [
    {
      "id": 123,
      "song_name": "Some Song",
      "day_released": "2025-01-05 12:34:56",
      "trend": "Bulgaria",
      "trend_flag": "https://popnable.com/images/flags/circle/bg.svg",
      "trend_id": 35,
      "singers": [
        { "singer_id": 777, "artist_name": "Preslava" }
      ],
      "videos": [
        { "yt_code": "AbCdE123" }
      ]
    }
  ],
  "meta": {
    "provider": "popnable",
    "upstream_response_code": 200,
    "upstream_error_number": null,
    "endpoint": "search"
  }
}
{
  "error": "Popnable: Access Denied.",
  "code": 403
}

Κωδικοί απάντησης

ΚωδικόςΠεριγραφή
200 SuccessΤο αίτημα επεξεργάστηκε επιτυχώς.
400 Bad RequestΗ επικύρωση εισόδου απέτυχε.
401 UnauthorizedΚλειδί API λείπει ή είναι λάθος.
403 ForbiddenΚλειδί ανενεργό ή μη επιτρεπόμενο.
429 Rate LimitΠάρα πολλά αιτήματα.
500 Server ErrorΜη αναμενόμενο σφάλμα.

music-popnable

music-popnable 0.0100 credits

Parameters

API Key
body · string · required
Action
body · string · required
Keyword
body · string
Trend IDs
body · string
Song IDs
body · string
Include Stats
body · string
Charts
body · string
Trend ID
body · string
Day
body · string
Artist IDs
body · string
Include Songs
body · string
YouTube Codes
body · string
Daily Stats
body · string

Code Samples


                
                
                
            

Response

Status:
Headers

                
Body

                

Music API by Popnable — Practical Guide

A hands-on guide to Music API by Popnable. Learn what each action does, the real-world problems it solves, which parameters actually matter, and how to read normalized responses for songs, artists, charts, trends and YouTube videos.

#What this API solves

One POST endpoint that proxies Popnable API and returns normalized JSON for search, trends, songs, artists, charts and YouTube videos. Use it when you need consistent data structures across multiple upstream calls, stable field names, predictable errors, and idempotent behavior suitable for caching.

#Endpoint & call model

#POST https://api.yeb.to/v1/music-popnable

  • Best for: Unified access to Popnable data with opinionated normalization.
  • How it works: You send an action plus its parameters; we call the corresponding Popnable v2 method and normalize the response.
  • Idempotent: Same input → same output; safe for caching and retries.
  • Billing: Each request costs a fixed amount of credits (see chip above), regardless of the action.

#Quick start

# 1) Search (songs/artists) by keyword
curl -X POST "https://api.yeb.to/v1/music-popnable" \
  -H "Content-Type: application/json" \
  -d '{ "api_key": "YOUR_KEY", "action": "search", "keyword": "preslava" }'
# 2) Songs by trend (country/region) for a specific day
curl -X POST "https://api.yeb.to/v1/music-popnable" \
  -H "Content-Type: application/json" \
  -d '{ "api_key": "YOUR_KEY", "action": "get-songs-by-trend",
        "trend": "35", "day": "2025-01-05", "stats": "yes", "charts": "daily,weekly" }'
# 3) YouTube videos (normalized + optional charts/daily breakdown)
curl -X POST "https://api.yeb.to/v1/music-popnable" \
  -H "Content-Type: application/json" \
  -d '{ "api_key": "YOUR_KEY", "action": "get-videos",
        "yt_codes": "AbCdE123,ZXCV987", "charts": "daily,weekly",
        "dailyStats": "yes", "day": "2025-01-05" }'

#Common parameters (used by all actions)

ParamRequiredWhat to pass (practical)Why it matters
api_key Yes Send server-side or via edge; avoid exposing in browser code. Auth & rate limiting.
action Yes One of: search, get-trends, get-songs, get-songs-by-trend, get-artists, get-artist-by-trend, get-daily-chart, get-weekly-chart, get-monthly-chart, get-artist-chart, get-videos. Selects the upstream Popnable v2 method.

#Actions explained (what each one solves)

Solves: quick lookup when you have a name fragment and need likely candidates (songs/artists).

ParamTypeReqNotes (practical)
keywordstringYesShort text (~20 chars). Use user input as-is (trimmed).
{
  "api_key": "YOUR_KEY",
  "action" : "search",
  "keyword": "preslava"
}
{
  "data": [
    { "id": 123, "song_name": "Some Song", "trend_id": 35, "singers": [ { "singer_id": 777, "artist_name": "Preslava" } ] }
  ],
  "meta": { "provider": "popnable", "upstream_response_code": 200, "endpoint": "search" }
}

Solves: obtain available trend IDs (countries/regions) to drive UI pickers or scheduled fetches.

ParamTypeReqNotes
idsstringNoComma-separated list of trend IDs to filter; omit to fetch all (subject to provider rules).

#action=get-songs

Solves: fetch details for known song IDs (e.g., to refresh a small cached set, or hydrate UI cards).

ParamTypeReqNotes
idsstringYesComma-separated song IDs.
statsstringNoyes/no include Popnable stats.
chartsstringNoComma list, e.g. daily,weekly.

#action=get-songs-by-trend

Solves: build daily feeds per country/region for discovery, newsletters, or archives.

ParamTypeReqNotes
trendstringYesTrend ID (country/region).
daystringYesDate YYYY-MM-DD.
statsstringNoyes/no.
chartsstringNoe.g. daily,weekly,monthly.

#action=get-artists

Solves: hydrate artist cards and detail pages from known IDs.

ParamTypeReqNotes
idsstringYesComma-separated artist IDs.
statsstringNoyes/no include artist stats.
chartsstringNoChart type (usually artists).
songsstringNoyes/no include songs for each artist.

#action=get-artist-by-trend

Solves: discover artists by country/region for a given day; useful for editorial picks.

ParamTypeReqNotes
trendstringYesTrend ID.
daystringYesDate YYYY-MM-DD.
statsstringNoyes/no.
chartsstringNoUsually artists.
songsstringNoyes/no include songs.

#Charts — daily/weekly/monthly/artist

Solves: pull historical chart snapshots for analytics, leaderboards, or recap posts.

ActionParamsNotes
get-daily-chart trend (string, req), day (YYYY-MM-DD, req) Country/region daily chart.
get-weekly-chart trend (string, req), day (YYYY-MM-DD, req) Weekly chart snapshot.
get-monthly-chart trend (string, req), day (YYYY-MM-DD, req) Monthly chart snapshot.
get-artist-chart trend (string, req), day (YYYY-MM-DD, req) Artists chart for the given trend/day.

#action=get-videos

Solves: normalize YouTube video data and optionally enrich with chart context and daily breakdowns.

ParamTypeReqNotes
yt_codesstringYesComma-separated video codes (AbCdE123).
chartsstringNoe.g. daily,weekly.
dailyStatsstringNoyes/no include daily breakdown.
daystringNoReference day YYYY-MM-DD.

#Reading & acting on responses

{
  "data": [
    {
      "id": 123,
      "song_name": "Some Song",
      "day_released": "2025-01-05 12:34:56",
      "trend": "Bulgaria",
      "trend_flag": "https://popnable.com/images/flags/circle/bg.svg",
      "trend_id": 35,
      "singers": [ { "singer_id": 777, "artist_name": "Preslava" } ],
      "videos":   [ { "yt_code": "AbCdE123" } ]
    }
  ],
  "meta": {
    "provider": "popnable",
    "upstream_response_code": 200,
    "upstream_error_number": null,
    "endpoint": "search"
  }
}
  • data — normalized records. Use directly in UI and storage.
  • meta.providerpopnable for transparency/debug.
  • meta.upstream_response_code — HTTP-equivalent status from upstream.
  • meta.endpoint — which upstream path we called (e.g., songs/by-trend).

#Typical errors & how to fix

{ "error": "Missing \"action\" parameter", "code": 422 }
{ "error": "Missing or empty \"ids\"", "code": 422 }
{ "error": "Popnable: Access Denied.", "code": 403 }
  • 422 missing/invalid: Ensure required params for the chosen action are present and non-empty.
  • 401 invalid key: Rotate your YEB key; call only from server/edge.
  • 502 availability: Upstream temporarily unavailable; retry with backoff.
  • 403 upstream denial: Access rules on provider side; validate your upstream configuration and inputs.

#Troubleshooting & field notes

  1. Dates: All day params are YYYY-MM-DD. Keep a single timezone (prefer UTC) in your app.
  2. Batching: For bulk imports, cap at ≤100 rps and reuse connections. Cache idempotent requests by full payload hash.
  3. Partial enrichment: Use stats/charts/dailyStats only when needed to keep latency and cost predictable.
  4. Stability: Field names are normalized; upstream changes are absorbed where possible and reflected in the Changelog below.

#API Changelog (latest changes)

2025-11-25
Improved error passthrough for upstream logical errors (meta.upstream_response_code now always set). Hardened input validation messages for all actions.
2025-11-10
Added optional dailyStats to get-videos. Unified day format across actions (YYYY-MM-DD).
2025-10-20
Normalized lists for singers and videos in song payloads. Deduplicated repeated fields.
2025-10-01
Public v1 release: search, get-trends, get-songs, get-songs-by-trend, get-artists, get-artist-by-trend, get-daily-chart, get-weekly-chart, get-monthly-chart, get-artist-chart, get-videos.

Συχνές Ερωτήσεις

Μπορείτε να ρωτήσετε για τραγούδια, καλλιτέχνες, τάσεις χωρών/περιοχών, ημερήσια/εβδομαδιαία/μηνιαία charts και στατιστικά βίντεο YouTube μέσω ενός ενιαίου endpoint.

Το API χρησιμοποιεί Popnable v2 - το ίδιο σύνολο δεδομένων που τροφοδοτεί τα δημόσια μουσικά charts του Popnable.

Τα charts ακολουθούν τον κύκλο ανανέωσης του Popnable. Τα ημερήσια charts ανανεώνονται περίπου κάθε 24 ώρες.

Ναι. Κάθε αίτημα, ακόμα και αυτά που καταλήγουν σε σφάλμα, καταναλώνει πιστωτικές μονάδες. Οι πιστωτικές μονάδες σας συνδέονται με τον αριθμό αιτημάτων, ανεξάρτητα από επιτυχία ή αποτυχία. Εάν το σφάλμα οφείλεται σαφώς σε πρόβλημα της πλατφόρμας από τη δική μας πλευρά, θα αποκαταστήσουμε τις επηρεαζόμενες πιστωτικές μονάδες (χωρίς επιστροφή χρημάτων).

Επικοινωνήστε μαζί μας στο [email protected]. Λαμβάνουμε τα σχόλια σοβαρά—εάν η αναφορά σφάλματος ή το αίτημα λειτουργίας είναι ουσιαστικό, μπορούμε να διορθώσουμε ή να βελτιώσουμε το API γρήγορα και να σας χορηγήσουμε 50 δωρεάν πιστωτικές μονάδες ως ευχαριστώ.

Εξαρτάται από το API και μερικές φορές ακόμα και από το endpoint. Ορισμένα endpoints χρησιμοποιούν δεδομένα από εξωτερικές πηγές, που μπορεί να έχουν αυστηρότερα όρια. Επιβάλλουμε επίσης όρια για να αποτρέψουμε κατάχρηση και να διατηρήσουμε την πλατφόρμα μας σταθερή. Ελέγξτε την τεκμηρίωση για το συγκεκριμένο όριο κάθε endpoint.

Λειτουργούμε με σύστημα πιστωτικών μονάδων. Οι πιστωτικές μονάδες είναι προπληρωμένες, μη επιστρέψιμες μονάδες που ξοδεύετε σε κλήσεις API και εργαλεία. Καταναλώνονται με τη μέθοδο FIFO (παλαιότερες πρώτα) και ισχύουν για 12 μήνες από την ημερομηνία αγοράς. Ο πίνακας ελέγχου δείχνει κάθε ημερομηνία αγοράς και τη λήξη της.

Ναι. Όλες οι αγορασμένες πιστωτικές μονάδες (συμπεριλαμβανομένων κλασματικών υπολοίπων) ισχύουν για 12 μήνες από την αγορά. Οι αχρησιμοποίητες πιστωτικές μονάδες λήγουν αυτόματα και διαγράφονται μόνιμα στο τέλος της περιόδου ισχύος. Οι ληγμένες πιστωτικές μονάδες δεν μπορούν να αποκατασταθούν ή να μετατραπούν σε μετρητά ή άλλη αξία. Μεταβατικός κανόνας: πιστωτικές μονάδες που αγοράστηκαν πριν τις 22 Σεπ. 2025 θεωρούνται αγορασμένες στις 22 Σεπ. 2025 και λήγουν στις 22 Σεπ. 2026 (εκτός αν αναφέρθηκε νωρίτερη λήξη κατά την αγορά).

Ναι—εντός της περιόδου ισχύος τους. Οι αχρησιμοποίητες πιστωτικές μονάδες παραμένουν διαθέσιμες και μεταφέρονται από μήνα σε μήνα μέχρι να λήξουν 12 μήνες μετά την αγορά.

Οι πιστωτικές μονάδες είναι μη επιστρέψιμες. Αγοράστε μόνο ό,τι χρειάζεστε—μπορείτε πάντα να αναπληρώσετε αργότερα. Εάν ένα σφάλμα πλατφόρμας προκαλέσει αποτυχημένη χρέωση, μπορούμε να αποκαταστήσουμε τις επηρεαζόμενες πιστωτικές μονάδες μετά από έρευνα. Καμία επιστροφή χρημάτων.

Οι τιμές ορίζονται σε πιστωτικές μονάδες, όχι σε δολάρια. Κάθε endpoint έχει το δικό του κόστος—δείτε το σήμα «Πιστωτικές μονάδες / αίτημα» παραπάνω. Θα ξέρετε πάντα ακριβώς τι ξοδεύετε.
← Πίσω στα API