# Apple Music Scraper (`unfenced-group/apple-music-scraper`) Actor

Scrape Apple Music albums, songs, artists and music videos with localized prices and availability across 50+ countries. Full album tracklists, charts, artwork, previews and metadata. No API key.

- **URL**: https://apify.com/unfenced-group/apple-music-scraper.md
- **Developed by:** [Unfenced Group](https://apify.com/unfenced-group) (community)
- **Categories:** E-commerce
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.19 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## Apple Music Scraper
![Banner](https://api.apify.com/v2/key-value-stores/lJlifu6C8YQfZMPKE/records/apple-music-scraper)

Scrape Apple Music albums, songs, artists and music videos with localized pricing and availability across 50+ countries in a single run. Get full album tracklists, charts, artwork, audio previews, genres and rich metadata — all from one search. No API key required, no login, no setup.

---

### Why this scraper?

#### 🌍 52 countries, native currencies, one run
Price and check availability for any album, song or video across the US, all of Europe, Latin America, Asia-Pacific and the Middle East at once. Every result carries each country's exact local price and currency.

#### 💿 Full album tracklists
Turn on tracklists and every album returns its complete track list — each track with title, number, duration, explicitness, a 30-second preview URL and its own Apple Music link. Most cheap scrapers stop at the album cover.

#### 📈 Browse the charts
Pull Apple Music's current most-played songs or albums for any country straight from Apple's official charts feed, then enrich every entry with full metadata and multi-country pricing.

#### 🎧 Albums, songs, artists and music videos
Search any combination of catalogue types in one run. Expand an artist into their full discography. Look up exact items by Apple ID or by pasting an Apple Music URL.

#### 🖼️ Media included
High-resolution artwork (up to 1200px), 30-second audio previews for songs, and video previews for music videos — every record.

#### 🎯 Powerful filtering
Filter by type, genre, explicit/clean, price band, release window and streamable status.

#### 💸 Pay only for results
Flat per-item pricing. You only pay for items actually returned. Filtered-out items and failed retries are never charged.

---

### Input parameters

| Field | Type | Default | Description |
|---|---|---|---|
| `searchQuery` | string | `""` | Keyword(s) to search Apple Music. Leave empty to browse charts or scrape IDs/URLs. |
| `entityTypes` | array | `["album","song"]` | What to return when searching: `album`, `song`, `artist`, `musicVideo`. |
| `browseCharts` | string | `""` | Browse the charts instead of searching: `songs` or `albums`. |
| `country` | string | `US` | Single storefront to price against. Also used for search/charts discovery. Ignored if `countries` or `allCountries` is set. |
| `countries` | array | `[]` | Multiple storefronts to price each item against in one run. |
| `allCountries` | boolean | `false` | Price across all 52 supported storefronts. Overrides the country fields. |
| `maxResults` | integer | `10` | Maximum number of items to return. |
| `searchLanguage` | string | `""` | Apple language code for localized titles/genres (e.g. `de_de`, `ja_jp`). Prices stay localized per country. |
| `appleIds` | array | `[]` | Exact Apple catalogue IDs (album/song/artist/video) to scrape directly. Bypasses search. |
| `startUrls` | array | `[]` | Apple Music / iTunes URLs to scrape directly. |
| `includeTracklist` | boolean | `false` | For albums, fetch the full tracklist. |
| `expandArtistAlbums` | boolean | `false` | When an artist is found, also scrape their albums. |
| `filterTypes` | array | `[]` | Keep only these types in the output. |
| `explicitFilter` | string | `all` | `all`, `clean`, or `explicit`. |
| `genres` | array | `[]` | Filter by genre (substring match — e.g. `pop`, `hip-hop`). |
| `minPrice` | integer | – | Only items whose lowest price across countries is at least this amount. |
| `maxPrice` | integer | – | Only items whose lowest price across countries is at most this amount. |
| `releasedAfter` | string | `""` | Only items released on or after this date (YYYY-MM-DD). |
| `releasedBefore` | string | `""` | Only items released on or before this date (YYYY-MM-DD). |
| `streamableOnly` | boolean | `false` | Only items currently streamable on Apple Music. |
| `includeMedia` | boolean | `true` | Include artwork and preview URLs. |
| `useProxy` | boolean | `false` | Route requests through Apify Proxy. Off by default. |

---

### Output schema

Every item returns the following fields.

| Field | Type | Description |
|---|---|---|
| `type` | string | `album`, `song`, `artist` or `musicVideo`. |
| `id` | string | Apple catalogue ID (the item's own ID). |
| `artistId` | string | Apple artist ID. |
| `collectionId` | string | Apple album/collection ID. |
| `trackId` | string | Apple track ID (songs and videos). |
| `amgArtistId` | string | Legacy AllMusic artist ID, when present. |
| `name` | string | Primary display name (track, album or artist). |
| `artistName` | string | Artist name. |
| `collectionName` | string | Album name. |
| `trackName` | string | Track name (songs and videos). |
| `censoredName` | string | Censored display name, when listed. |
| `primaryGenre` | string | Primary genre. |
| `primaryGenreId` | string | Apple genre ID. |
| `artistType` | string | Artist type, for artist records. |
| `collectionType` | string | Collection type (e.g. Album). |
| `trackNumber` | number | Track position within the album. |
| `trackCount` | number | Number of tracks in the album. |
| `discNumber` | number | Disc number. |
| `discCount` | number | Number of discs. |
| `durationMs` | number | Track duration in milliseconds. |
| `durationSec` | number | Track duration in seconds. |
| `explicit` | boolean | Whether the item is explicit. |
| `trackExplicit` | boolean | Track-level explicit flag. |
| `collectionExplicit` | boolean | Album-level explicit flag. |
| `isStreamable` | boolean | Whether the item is streamable. |
| `maturity` | string | `clean`, `explicit` or `unknown`. |
| `copyright` | string | Copyright / rights line (often names the label). |
| `releaseDate` | string | Release date (ISO 8601). |
| `artworkUrl` | string | Artwork URL. |
| `artworkUrlHiRes` | string | High-resolution artwork URL (up to 1200px). |
| `previewUrl` | string | 30-second audio (or video) preview URL. |
| `appleMusicUrl` | string | Apple Music link to the item. |
| `artistUrl` | string | Apple Music link to the artist. |
| `collectionUrl` | string | Apple Music link to the album. |
| `chartRank` | number | Position in the charts, when browsing charts. |
| `prices` | array | Per-country price/availability blocks (see below). |
| `priceByCountry` | object | The same prices keyed by country code. |
| `countriesPriced` | number | How many countries returned a price/availability record. |
| `lowestPrice` | number | Lowest price across all priced countries in this run. |
| `tracks` | array | Full album tracklist (only when `includeTracklist` is on). |
| `scrapedAt` | string | Timestamp of the scrape (ISO 8601). |

Each entry in `prices` contains:

| Field | Type | Description |
|---|---|---|
| `country` | string | ISO country code. |
| `countryName` | string | Country name. |
| `currency` | string | Local currency code. |
| `trackPrice` | number | Track buy price, when sold individually. |
| `collectionPrice` | number | Album buy price, when sold. |
| `finalPrice` | number | Effective buy price (track price if present, else album price). |
| `isAvailable` | boolean | The item exists in this storefront. |
| `isStreamable` | boolean | Streamable in this country. |
| `appleMusicUrl` | string | Apple Music link for this storefront. |

Each entry in `tracks` (when enabled) contains: `trackId`, `trackNumber`, `discNumber`, `trackName`, `durationMs`, `durationSec`, `explicit`, `isStreamable`, `previewUrl`, `trackPrice`, `appleMusicUrl`.

#### Example record

```json
{
  "type": "album",
  "id": "1468058165",
  "artistId": "159260351",
  "collectionId": "1468058165",
  "name": "Lover",
  "artistName": "Taylor Swift",
  "collectionName": "Lover",
  "primaryGenre": "Pop",
  "trackCount": 18,
  "explicit": false,
  "copyright": "℗ 2019 Taylor Swift",
  "releaseDate": "2019-08-23T07:00:00Z",
  "artworkUrl": "https://is1-ssl.mzstatic.com/image/thumb/.../100x100bb.jpg",
  "artworkUrlHiRes": "https://is1-ssl.mzstatic.com/image/thumb/.../1200x1200bb.jpg",
  "appleMusicUrl": "https://music.apple.com/us/album/lover/1468058165",
  "prices": [
    { "country": "US", "countryName": "United States", "currency": "USD", "collectionPrice": 11.99, "finalPrice": 11.99, "isAvailable": true },
    { "country": "GB", "countryName": "United Kingdom", "currency": "GBP", "collectionPrice": 9.99, "finalPrice": 9.99, "isAvailable": true },
    { "country": "JP", "countryName": "Japan", "currency": "JPY", "collectionPrice": 2037, "finalPrice": 2037, "isAvailable": true }
  ],
  "countriesPriced": 3,
  "lowestPrice": 9.99,
  "tracks": [
    { "trackNumber": 1, "trackName": "I Forgot That You Existed", "durationSec": 171, "explicit": false, "previewUrl": "https://audio-ssl.itunes.apple.com/...m4a" },
    { "trackNumber": 2, "trackName": "Cruel Summer", "durationSec": 178, "explicit": false, "previewUrl": "https://audio-ssl.itunes.apple.com/...m4a" }
  ],
  "scrapedAt": "2026-06-24T04:33:00.000Z"
}
````

***

### Examples

**1. Search a song and compare prices across countries**

```json
{
  "searchQuery": "blinding lights",
  "entityTypes": ["song"],
  "countries": ["US", "GB", "DE", "JP", "BR"],
  "maxResults": 5
}
```

**2. Scrape an album with its full tracklist**

```json
{
  "searchQuery": "tears of the kingdom",
  "entityTypes": ["album"],
  "includeTracklist": true,
  "country": "US",
  "maxResults": 3
}
```

**3. Browse the top albums chart in the UK**

```json
{
  "browseCharts": "albums",
  "country": "GB",
  "maxResults": 25
}
```

**4. Daily price feed for specific IDs across every storefront**

```json
{
  "appleIds": ["1468058165", "1488408555"],
  "allCountries": true
}
```

***

### 💰 Pricing

**$1.49 per 1,000 items** — you only pay for items actually returned. Failed retries and filtered-out items are never charged.

| Items | Cost |
|---|---|
| 100 | ~$0.15 |
| 1,000 | ~$1.49 |
| 10,000 | ~$14.90 |
| 100,000 | ~$149.00 |

Subscribers pay less at every tier, down to **$0.89 per 1,000** on the Diamond plan.

> Flat-rate alternatives typically charge $5 per 1,000 results.

Use the **Max results** cap in the input to control your spend exactly.

***

### Performance

| Run size | Approx. time |
|---|---|
| 10 items × 1 country | ~10 s |
| 50 items × 5 countries | ~60 s |
| 100 items × all countries | ~5 min |

Multi-country runs add one fast pricing pass per country. Memory stays under 100 MB.

***

### Known limitations

- Buy prices reflect what Apple exposes per storefront; many catalogue items are streaming-only and return availability without a buy price.
- Tracklists are fetched for albums only, in the primary country.
- Region-exclusive titles only appear in the storefronts that carry them.

***

### Technical details

- **Source:** Apple's public iTunes Search and Lookup APIs and the official Apple Music charts feed.
- **Memory:** 512 MB.
- **Retry:** Automatic retry on network errors, exponential backoff, 3 attempts per request.
- **Output:** Every run writes an `OUTPUT` summary and a `HEALTH` status to the key-value store.

***

### Run it on a schedule

This actor is built for repeat use. Set it to run daily, weekly, or hourly, and the data keeps flowing without you touching it.

- **Schedule runs** — open the actor, go to Schedules, and pick a cadence. Each run only charges you for the results it returns.
- **Connect it to your stack** — push results straight to Google Sheets, Slack, a webhook, or your database using Apify Integrations. No glue code needed.
- **Pull results via API** — every run writes a clean dataset you can fetch with one API call, ready for whatever you build on top of it.

Set it once and it runs on its own.

***

### Need a custom scraper?

**[Unfenced Group](https://www.unfencedgroup.nl)** builds Apify actors for any website — for free.

If the site you need isn't in our portfolio yet, just ask. We scope, build, and publish it at no cost to you. You only pay for results — we absorb the compute and proxy costs ourselves. Same pay-per-result pricing, same quality, same standards as every actor in this portfolio.

**Get in touch:** [www.unfencedgroup.nl](https://www.unfencedgroup.nl)

# Actor input Schema

## `searchQuery` (type: `string`):

Keyword(s) to search Apple Music (e.g. "taylor swift", "blinding lights"). Leave empty to browse the charts or to scrape specific IDs/URLs.

## `entityTypes` (type: `array`):

Which catalogue types to return when searching by keyword. Ignored when browsing charts or scraping IDs/URLs.

## `browseCharts` (type: `string`):

Pull Apple Music's current most-played chart instead of searching. Uses the official Apple charts feed for the primary country.

## `country` (type: `string`):

Single storefront to price against. Ignored if 'Countries' or 'All countries' is set. The first selected country is also used for search and charts discovery.

## `countries` (type: `array`):

Price each item across multiple storefronts in one run — every selected country's local price, currency and availability is returned per item.

## `allCountries` (type: `boolean`):

Price across all 52 supported storefronts in a single run. Overrides the country fields.

## `maxResults` (type: `integer`):

Maximum number of items (albums/songs/artists/videos) to return.

## `searchLanguage` (type: `string`):

Optional Apple language code for localized titles and genres (e.g. "en\_us", "de\_de", "ja\_jp"). Leave empty for each storefront's default. Prices stay localized per country regardless.

## `appleIds` (type: `array`):

Optional list of exact Apple catalogue IDs (album, song, artist or music-video IDs, e.g. 1468058165) to scrape directly. Bypasses search.

## `startUrls` (type: `array`):

Optional list of Apple Music / iTunes URLs to scrape directly (album, song, artist or music-video pages).

## `includeTracklist` (type: `boolean`):

For albums, fetch the full tracklist (every track with duration, preview URL, explicitness and track number). Adds one fast request per album.

## `expandArtistAlbums` (type: `boolean`):

When an artist is found, also scrape that artist's albums (their discography).

## `filterTypes` (type: `array`):

Post-filter: keep only items of these types in the output.

## `explicitFilter` (type: `string`):

Restrict to clean or explicit items only.

## `genres` (type: `array`):

Filter by genre (substring match, case-insensitive — e.g. "pop", "hip-hop", "rock").

## `minPrice` (type: `integer`):

Only items whose lowest price across selected countries is at least this amount (local major units).

## `maxPrice` (type: `integer`):

Only items whose lowest price across selected countries is at most this amount (local major units).

## `releasedAfter` (type: `string`):

Only items released on or after this date (YYYY-MM-DD).

## `releasedBefore` (type: `string`):

Only items released on or before this date (YYYY-MM-DD).

## `streamableOnly` (type: `boolean`):

Only items currently streamable on Apple Music.

## `includeMedia` (type: `boolean`):

Include artwork and audio/video preview URLs.

## `useProxy` (type: `boolean`):

Route requests through Apify Proxy. Off by default — the Apple endpoints are reachable directly.

## Actor input object example

```json
{
  "searchQuery": "",
  "entityTypes": [
    "album",
    "song"
  ],
  "browseCharts": "",
  "country": "US",
  "countries": [],
  "allCountries": false,
  "maxResults": 10,
  "searchLanguage": "",
  "appleIds": [],
  "startUrls": [],
  "includeTracklist": false,
  "expandArtistAlbums": false,
  "filterTypes": [],
  "explicitFilter": "all",
  "genres": [],
  "releasedAfter": "",
  "releasedBefore": "",
  "streamableOnly": false,
  "includeMedia": true,
  "useProxy": false
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("unfenced-group/apple-music-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("unfenced-group/apple-music-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call unfenced-group/apple-music-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=unfenced-group/apple-music-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Apple Music Scraper",
        "description": "Scrape Apple Music albums, songs, artists and music videos with localized prices and availability across 50+ countries. Full album tracklists, charts, artwork, previews and metadata. No API key.",
        "version": "0.0",
        "x-build-id": "06Dy8IahaOZa77o8N"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/unfenced-group~apple-music-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-unfenced-group-apple-music-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/unfenced-group~apple-music-scraper/runs": {
            "post": {
                "operationId": "runs-sync-unfenced-group-apple-music-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/unfenced-group~apple-music-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-unfenced-group-apple-music-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {
                    "searchQuery": {
                        "title": "Search query",
                        "type": "string",
                        "description": "Keyword(s) to search Apple Music (e.g. \"taylor swift\", \"blinding lights\"). Leave empty to browse the charts or to scrape specific IDs/URLs.",
                        "default": ""
                    },
                    "entityTypes": {
                        "title": "What to search for",
                        "type": "array",
                        "description": "Which catalogue types to return when searching by keyword. Ignored when browsing charts or scraping IDs/URLs.",
                        "items": {
                            "type": "string",
                            "enum": [
                                "album",
                                "song",
                                "artist",
                                "musicVideo"
                            ],
                            "enumTitles": [
                                "Albums",
                                "Songs",
                                "Artists",
                                "Music videos"
                            ]
                        },
                        "default": [
                            "album",
                            "song"
                        ]
                    },
                    "browseCharts": {
                        "title": "Browse charts",
                        "enum": [
                            "",
                            "songs",
                            "albums"
                        ],
                        "type": "string",
                        "description": "Pull Apple Music's current most-played chart instead of searching. Uses the official Apple charts feed for the primary country.",
                        "default": ""
                    },
                    "country": {
                        "title": "Country (single)",
                        "enum": [
                            "US",
                            "CA",
                            "MX",
                            "BR",
                            "AR",
                            "CL",
                            "CO",
                            "PE",
                            "GB",
                            "IE",
                            "DE",
                            "FR",
                            "NL",
                            "BE",
                            "LU",
                            "ES",
                            "PT",
                            "IT",
                            "AT",
                            "CH",
                            "PL",
                            "CZ",
                            "SE",
                            "NO",
                            "DK",
                            "FI",
                            "GR",
                            "HU",
                            "RO",
                            "RU",
                            "UA",
                            "TR",
                            "AU",
                            "NZ",
                            "JP",
                            "KR",
                            "CN",
                            "HK",
                            "TW",
                            "SG",
                            "MY",
                            "TH",
                            "ID",
                            "PH",
                            "VN",
                            "IN",
                            "AE",
                            "SA",
                            "IL",
                            "EG",
                            "ZA",
                            "NG"
                        ],
                        "type": "string",
                        "description": "Single storefront to price against. Ignored if 'Countries' or 'All countries' is set. The first selected country is also used for search and charts discovery.",
                        "default": "US"
                    },
                    "countries": {
                        "title": "Countries (multi-select)",
                        "type": "array",
                        "description": "Price each item across multiple storefronts in one run — every selected country's local price, currency and availability is returned per item.",
                        "items": {
                            "type": "string",
                            "enum": [
                                "US",
                                "CA",
                                "MX",
                                "BR",
                                "AR",
                                "CL",
                                "CO",
                                "PE",
                                "GB",
                                "IE",
                                "DE",
                                "FR",
                                "NL",
                                "BE",
                                "LU",
                                "ES",
                                "PT",
                                "IT",
                                "AT",
                                "CH",
                                "PL",
                                "CZ",
                                "SE",
                                "NO",
                                "DK",
                                "FI",
                                "GR",
                                "HU",
                                "RO",
                                "RU",
                                "UA",
                                "TR",
                                "AU",
                                "NZ",
                                "JP",
                                "KR",
                                "CN",
                                "HK",
                                "TW",
                                "SG",
                                "MY",
                                "TH",
                                "ID",
                                "PH",
                                "VN",
                                "IN",
                                "AE",
                                "SA",
                                "IL",
                                "EG",
                                "ZA",
                                "NG"
                            ],
                            "enumTitles": [
                                "🇺🇸 United States (USD)",
                                "🇨🇦 Canada (CAD)",
                                "🇲🇽 Mexico (MXN)",
                                "🇧🇷 Brazil (BRL)",
                                "🇦🇷 Argentina (ARS)",
                                "🇨🇱 Chile (CLP)",
                                "🇨🇴 Colombia (COP)",
                                "🇵🇪 Peru (PEN)",
                                "🇬🇧 United Kingdom (GBP)",
                                "🇮🇪 Ireland (EUR)",
                                "🇩🇪 Germany (EUR)",
                                "🇫🇷 France (EUR)",
                                "🇳🇱 Netherlands (EUR)",
                                "🇧🇪 Belgium (EUR)",
                                "🇱🇺 Luxembourg (EUR)",
                                "🇪🇸 Spain (EUR)",
                                "🇵🇹 Portugal (EUR)",
                                "🇮🇹 Italy (EUR)",
                                "🇦🇹 Austria (EUR)",
                                "🇨🇭 Switzerland (CHF)",
                                "🇵🇱 Poland (PLN)",
                                "🇨🇿 Czechia (CZK)",
                                "🇸🇪 Sweden (SEK)",
                                "🇳🇴 Norway (NOK)",
                                "🇩🇰 Denmark (DKK)",
                                "🇫🇮 Finland (EUR)",
                                "🇬🇷 Greece (EUR)",
                                "🇭🇺 Hungary (HUF)",
                                "🇷🇴 Romania (RON)",
                                "🇷🇺 Russia (RUB)",
                                "🇺🇦 Ukraine (UAH)",
                                "🇹🇷 Turkey (TRY)",
                                "🇦🇺 Australia (AUD)",
                                "🇳🇿 New Zealand (NZD)",
                                "🇯🇵 Japan (JPY)",
                                "🇰🇷 South Korea (KRW)",
                                "🇨🇳 China (CNY)",
                                "🇭🇰 Hong Kong (HKD)",
                                "🇹🇼 Taiwan (TWD)",
                                "🇸🇬 Singapore (SGD)",
                                "🇲🇾 Malaysia (MYR)",
                                "🇹🇭 Thailand (THB)",
                                "🇮🇩 Indonesia (IDR)",
                                "🇵🇭 Philippines (PHP)",
                                "🇻🇳 Vietnam (VND)",
                                "🇮🇳 India (INR)",
                                "🇦🇪 United Arab Emirates (AED)",
                                "🇸🇦 Saudi Arabia (SAR)",
                                "🇮🇱 Israel (ILS)",
                                "🇪🇬 Egypt (EGP)",
                                "🇿🇦 South Africa (ZAR)",
                                "🇳🇬 Nigeria (NGN)"
                            ]
                        },
                        "default": []
                    },
                    "allCountries": {
                        "title": "All countries",
                        "type": "boolean",
                        "description": "Price across all 52 supported storefronts in a single run. Overrides the country fields.",
                        "default": false
                    },
                    "maxResults": {
                        "title": "Max results",
                        "minimum": 1,
                        "type": "integer",
                        "description": "Maximum number of items (albums/songs/artists/videos) to return.",
                        "default": 10
                    },
                    "searchLanguage": {
                        "title": "Result language",
                        "type": "string",
                        "description": "Optional Apple language code for localized titles and genres (e.g. \"en_us\", \"de_de\", \"ja_jp\"). Leave empty for each storefront's default. Prices stay localized per country regardless.",
                        "default": ""
                    },
                    "appleIds": {
                        "title": "Specific Apple IDs",
                        "type": "array",
                        "description": "Optional list of exact Apple catalogue IDs (album, song, artist or music-video IDs, e.g. 1468058165) to scrape directly. Bypasses search.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "startUrls": {
                        "title": "Start URLs",
                        "type": "array",
                        "description": "Optional list of Apple Music / iTunes URLs to scrape directly (album, song, artist or music-video pages).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "includeTracklist": {
                        "title": "Include album tracklists",
                        "type": "boolean",
                        "description": "For albums, fetch the full tracklist (every track with duration, preview URL, explicitness and track number). Adds one fast request per album.",
                        "default": false
                    },
                    "expandArtistAlbums": {
                        "title": "Expand artists to albums",
                        "type": "boolean",
                        "description": "When an artist is found, also scrape that artist's albums (their discography).",
                        "default": false
                    },
                    "filterTypes": {
                        "title": "Keep only these types",
                        "type": "array",
                        "description": "Post-filter: keep only items of these types in the output.",
                        "items": {
                            "type": "string",
                            "enum": [
                                "album",
                                "song",
                                "artist",
                                "musicVideo"
                            ],
                            "enumTitles": [
                                "Albums",
                                "Songs",
                                "Artists",
                                "Music videos"
                            ]
                        },
                        "default": []
                    },
                    "explicitFilter": {
                        "title": "Explicit content",
                        "enum": [
                            "all",
                            "clean",
                            "explicit"
                        ],
                        "type": "string",
                        "description": "Restrict to clean or explicit items only.",
                        "default": "all"
                    },
                    "genres": {
                        "title": "Genres",
                        "type": "array",
                        "description": "Filter by genre (substring match, case-insensitive — e.g. \"pop\", \"hip-hop\", \"rock\").",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "minPrice": {
                        "title": "Minimum price",
                        "type": "integer",
                        "description": "Only items whose lowest price across selected countries is at least this amount (local major units)."
                    },
                    "maxPrice": {
                        "title": "Maximum price",
                        "type": "integer",
                        "description": "Only items whose lowest price across selected countries is at most this amount (local major units)."
                    },
                    "releasedAfter": {
                        "title": "Released after",
                        "type": "string",
                        "description": "Only items released on or after this date (YYYY-MM-DD).",
                        "default": ""
                    },
                    "releasedBefore": {
                        "title": "Released before",
                        "type": "string",
                        "description": "Only items released on or before this date (YYYY-MM-DD).",
                        "default": ""
                    },
                    "streamableOnly": {
                        "title": "Streamable only",
                        "type": "boolean",
                        "description": "Only items currently streamable on Apple Music.",
                        "default": false
                    },
                    "includeMedia": {
                        "title": "Include media",
                        "type": "boolean",
                        "description": "Include artwork and audio/video preview URLs.",
                        "default": true
                    },
                    "useProxy": {
                        "title": "Use proxy",
                        "type": "boolean",
                        "description": "Route requests through Apify Proxy. Off by default — the Apple endpoints are reachable directly.",
                        "default": false
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
