Schema reference
Schema version 1 · engine ANISURGE · single UTF-8 JSON file ending in .asx
Top-level fields
| Field | Type | Required | Notes |
|---|---|---|---|
schemaVersion | int | yes | Must be 1 |
id | string | yes | [a-z0-9-]+ |
name | string | yes | Display name |
version | string | yes | UI string, e.g. 1.2.0 |
versionCode | int | yes | Monotonic; used for updates |
language | string | no | Default all |
nsfw | bool | no | Default false |
description | string | no | |
author / homepage / iconUrl | string | no | |
minAppVersionCode | int | no | Skip if app is older |
capabilities | object | no | subDub, resolveBy[] |
defaults.headers | object | no | Merged into each http.get |
pipeline.resolve | array | yes | Non-empty step list |
Steps
http.get
{
"step": "http.get",
"url": "https://example.com/x/{{anilistId}}/{{episode}}",
"headers": { "Accept": "text/html" },
"saveAs": "pageHtml",
"optional": false
}
- Merges
defaults.headers, then step headers - Saves response body text to
saveAs - Non-2xx fails unless
optional: true
extract.regex
{
"step": "extract.regex",
"from": "pageHtml",
"pattern": "data-id=\"(\\d+)\"",
"group": 1,
"saveAs": "dataId",
"onlyIfMissing": "dataId"
}
json.parse / json.get
{ "step": "json.parse", "from": "sourcesBody", "saveAs": "sources" }
{ "step": "json.get", "from": "sources", "path": "sources.file", "saveAs": "streamUrl" }
map.videos
{
"step": "map.videos",
"file": "{{sources.sources.file}}",
"quality": "Auto",
"headers": { "Referer": "https://example.com/" },
"subtitles": {
"from": "sources.tracks",
"urlKey": "file",
"labelKey": "label"
},
"intro": "sources.intro",
"outro": "sources.outro"
}
try
Ordered branches; first that completes without error wins. Optional when:
| op | Meaning |
|---|---|
gt | numeric greater than value |
eq | equality |
exists | var non-empty |
index.json
{
"schemaVersion": 1,
"name": "Anisurge Official Extensions",
"engine": "ANISURGE",
"extensions": [
{
"id": "anokoto",
"name": "Anokoto",
"version": "1.0.0",
"versionCode": 1,
"downloadUrl": "https://raw.githubusercontent.com/Anisurge/extensions/main/extensions/anokoto/anokoto.asx",
"minAppVersionCode": 140
}
]
}