Australian AI Music Alliance

ISRC-AAM-CID API

Batch code issuance for AI music platforms. 面向 AI 音乐平台的批量发码接口。

Authentication

身份认证

Every request carries an API key issued in the developer portal. Send it as a bearer token (or the x-api-key header). Live keys start with aam_live_, sandbox keys with aam_test_. 密钥只在创建时显示一次,请妥善保存。

Authorization: Bearer aam_live_xxxxxxxxxxxxxxxxxxxx

Sandbox

沙盒环境

A sandbox key hits the same endpoints and returns the same response shape, but codes are prefixed TEST, are stored separately, and never consume a live serial number. 沙盒数据可在开发者门户一键清空。

POST /api/public/register

单条发码

curl -X POST https://auaimusic.com/api/public/register \
  -H "Authorization: Bearer $AAM_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Neon Harbour",
    "artist": "Studio Aurora",
    "ai_involvement": "assisted",
    "generator": "Suno v4",
    "external_ref": "platform-track-10231",
    "duration_seconds": 214,
    "release_date": "2026-09-01"
  }'
{ "code": "AUR7L2610632-AAM2-CID...", "created": true, "environment": "live", "request_id": "..." }

POST /api/public/register-batch

批量发码(最多 500 条)

Send up to 500 items in one request. Include an Idempotency-Key header so a retried request returns the original result instead of issuing new codes.

curl -X POST https://auaimusic.com/api/public/register-batch \
  -H "Authorization: Bearer $AAM_KEY" \
  -H "Idempotency-Key: 2026-09-19-batch-001" \
  -H "Content-Type: application/json" \
  -d '{ "items": [ { "title": "A", "artist": "B", "external_ref": "ref-1" } ] }'
{
  "job_id": "…", "submitted": 1, "created": 1, "duplicates": 0, "failed": 0,
  "items": [ { "external_ref": "ref-1", "status": "created", "code": "AUR7L26…" } ]
}

JavaScript

const res = await fetch("https://auaimusic.com/api/public/register-batch", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.AAM_KEY}`,
    "Content-Type": "application/json",
    "Idempotency-Key": batchId,
  },
  body: JSON.stringify({ items }),
});
const data = await res.json();

Python

import os, requests

res = requests.post(
    "https://auaimusic.com/api/public/register-batch",
    headers={
        "Authorization": f"Bearer {os.environ['AAM_KEY']}",
        "Idempotency-Key": batch_id,
    },
    json={"items": items},
    timeout=60,
)
print(res.json())

GET /api/public/register-job/{id}

查询批次结果

curl -H "Authorization: Bearer $AAM_KEY" https://auaimusic.com/api/public/register-job/JOB_ID

GET /api/public/verify?code=

校验编码

curl -H "Authorization: Bearer $AAM_KEY" "https://auaimusic.com/api/public/verify?code=AUR7L2610632-AAM2-CID..."

Field dictionary

字段说明

  • title, artist — required.
  • external_ref — required, your own stable id; duplicates return the existing code.
  • ai_involvement — human | assisted | full, applied to all default roles.
  • role_entries — optional per-role declaration: label, weight, level; weights must total 100 and labels must be unique.
  • generator, prompt, lyrics, genre, language, duration_seconds, release_date, provenance_url, work_cid, cover_cid, contact_email — optional.

AI score and AAM level

AI 分数与 AAM 等级

Each declared role has a weight and an AI level: no AI = 0, AI-assisted = 50, AI-generated = 100. The AI score is the weight-averaged value over all roles.

  • 0 → AAM0 · Fully human-created
  • ≤ 20 → AAM1 · Primarily human-created
  • ≤ 50 → AAM2 · Partially AI-assisted
  • ≤ 80 → AAM3 · Deep AI involvement
  • > 80 → AAM4 · Primarily AI-generated

The issued code is ISRC-AAM level-content id.

Rate limits, idempotency and errors

限流、幂等与错误码

  • 60 requests/minute for single registration and verify; 120/minute for batch and job lookup.
  • Every response carries X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset and X-Request-Id.
  • Idempotency works twice over: the Idempotency-Key header for the whole batch, and external_ref for each item.
  • 401 unauthorised · 400 invalid payload · 404 not found · 429 rate limited · 500 server error.

Migrating from the legacy shared key

从旧版共享密钥迁移

The previous single shared key still works unchanged. To migrate, create a live key in the developer portal, swap the value in your environment, and confirm issuance appears under your organisation. No payload or response change is required.