{
  "openapi": "3.0.1",
  "info": {
    "title": "MLC Rights Resolver: ISRC to ISWC, Writers, Publisher Shares",
    "description": "Resolve ISRCs or MLC song codes against the MLC Public Search API into a catalog-exposure report: how many resolved with writer, publisher, and share data, how many have no shares on file, and how many The MLC has no record of, plus one JSON row per identifier. Not affiliated with The MLC.",
    "version": "0.0",
    "x-build-id": "BZ2Xwu1QZKug9A2dn"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/yungstentech~mlc-works-resolver/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-yungstentech-mlc-works-resolver",
        "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/yungstentech~mlc-works-resolver/runs": {
      "post": {
        "operationId": "runs-sync-yungstentech-mlc-works-resolver",
        "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/yungstentech~mlc-works-resolver/run-sync": {
      "post": {
        "operationId": "run-sync-yungstentech-mlc-works-resolver",
        "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": {
          "identifiers": {
            "title": "Identifiers (ISRCs or MLC song codes)",
            "type": "array",
            "description": "A list of ISRCs or MLC song codes to resolve. Each item is either a string (auto-detected as an ISRC or MLC song code) or an object like {\"isrc\": \"...\", \"title\": \"...\", \"artist\": \"...\"} where explicit keys bypass detection and title/artist feed the optional fuzzy fallback. ISWC is an OUTPUT field only: the MLC public API has no ISWC lookup path, so ISWC inputs return a free \"unsupported\" row."
          },
          "csvUrl": {
            "title": "CSV URL (alternative to the list above)",
            "type": "string",
            "description": "An https:// URL to a CSV. The identifier column is the first header matching isrc / songCode / identifier / id (case-insensitive), otherwise column 1. Optional title and artist columns feed the fuzzy fallback. A file with a single identifier per line and no header also works."
          },
          "includeExposureReport": {
            "title": "Include catalog-exposure report",
            "type": "boolean",
            "description": "Produce one summary REPORT flagging the tracks worth investigating (not-found and no-shares-on-file). Charges catalog-exposure-report once: $3.00 on a Free plan, $15.00 Starter, $13.50 Scale, $12.00 Business. You get it only when the whole list finished and the run's remaining charge budget covers it; otherwise it is neither generated nor charged, and OUTPUT.reportWithheldReason says why.",
            "default": false
          },
          "enableFuzzyFallback": {
            "title": "Enable fuzzy title/artist fallback",
            "type": "boolean",
            "description": "For not-found ISRCs that also carry title (and optionally artist) metadata, attempt a best-effort title/artist search (hard cap of 2 extra MLC calls per item). Matches are flagged with matchMethod \"fuzzy-title\". Those 2 calls wait out the pace like any other, and that wait is runtime the actor pays for, so the attempt is skipped when the run's effective pace makes them cost more than a not-found row's charge can carry. At the default 6000 ms pacing, on default Run options, a run that has the MLC seat to itself never skips the attempt; raising pacingMs, another run sharing the seat, or a slowdown after upstream rate limiting can. OUTPUT.fuzzySkipped counts the skips and the run log names the pace that caused them; lowering pacingMs (minimum 1500) gets the attempt back.",
            "default": false
          },
          "includeRawWork": {
            "title": "Include raw MLC work JSON",
            "type": "boolean",
            "description": "Attach the raw MLC work object under rawWork on each resolved row (useful for agents that want every field).",
            "default": false
          },
          "pacingMs": {
            "title": "Pacing between MLC calls (ms)",
            "minimum": 1500,
            "maximum": 12000,
            "type": "integer",
            "description": "Delay between MLC API calls to respect the shared paid seat. Clamped to 1500-12000 ms in code. An ISRC takes about two paced calls (the recording search, then the work fetch), so the default 6000 ms works out to roughly 12.5 s per ISRC and 100 ISRCs takes about 21 minutes. Values below the default raise the chance of upstream rate limiting; the Actor backs off and slows itself when that happens. The 12000 ms ceiling exists because a paced call is runtime the Actor pays for, and beyond it a not-found row would cost more than it charges.",
            "default": 6000
          },
          "maxItems": {
            "title": "Max identifiers to process",
            "minimum": 1,
            "maximum": 2000,
            "type": "integer",
            "description": "Upper limit on how many (deduplicated) identifiers to process this run, and your row-charge ceiling: a row costs at most $0.03 on a Free or Starter plan ($0.027 Scale, $0.024 Business), so 100 identifiers is at most $3.00 in row charges, plus the report if you asked for one. A cap below your list size cuts the list short, which withholds the report. It is a ceiling, not a promise the whole list finishes: a run also stops at its platform timeout, and at the default pacing a 1-hour run resolves roughly 200-280 ISRCs, so raise the run timeout or split larger lists across runs. Nothing left unprocessed is charged; OUTPUT reports how many identifiers were skipped, and OUTPUT.note why when a run stopped early.",
            "default": 500
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}