API Reference

Anthias API v2.0.0 — manage assets, device settings, backups, and integrations over HTTP.

assets

get /api/v2/assets

Responses

200

Array of:

AssetSerializerV2

FieldTypeNotes
asset_id*stringread-only
durationinteger (int64) | null
end_datestring (date-time) | null
is_active*booleanread-only
is_enabledboolean
is_processingboolean
mimetypestring | null
namestring | null
nocacheboolean
play_orderinteger (int64)
skip_asset_checkboolean
start_datestring (date-time) | null
uristring | null
post /api/v2/assets

Request body application/json

Schema: CreateAssetSerializerV2

FieldTypeNotes
asset_id*stringread-only
duration*integer
end_date*string (date-time)
extstringwrite-only
is_enabled*boolean
is_processingboolean
mimetype*string
name*string
nocacheboolean
play_orderinteger
skip_asset_checkboolean
start_date*string (date-time)
uri*string

Responses

201

Schema: AssetSerializerV2

FieldTypeNotes
asset_id*stringread-only
durationinteger (int64) | null
end_datestring (date-time) | null
is_active*booleanread-only
is_enabledboolean
is_processingboolean
mimetypestring | null
namestring | null
nocacheboolean
play_orderinteger (int64)
skip_asset_checkboolean
start_datestring (date-time) | null
uristring | null
get /api/v2/assets/control/{command}

Use any of the following commands to control asset playback: * `next` - Show the next asset * `previous` - Show the previous asset * `asset&{asset_id}` - Show the asset with the specified `asset_id`

Parameters

NameInTypeRequired
commandpathstringyes

Responses

200

string

post /api/v2/assets/order

Request body application/json

Schema: PlaylistOrderSerializerMixin

FieldTypeNotes
ids*stringComma-separated list of asset IDs in the order they should be played. For example: `793406aa1fd34b85aa82614004c0e63a,1c5cfa719d1f4a9abae16c983a18903b,9c41068f3b7e452baf4dc3f9b7906595`write-only

Responses

204 No response body
get /api/v2/assets/{asset_id}

Parameters

NameInTypeRequired
asset_idpathstringyes

Responses

200

Schema: AssetSerializerV2

FieldTypeNotes
asset_id*stringread-only
durationinteger (int64) | null
end_datestring (date-time) | null
is_active*booleanread-only
is_enabledboolean
is_processingboolean
mimetypestring | null
namestring | null
nocacheboolean
play_orderinteger (int64)
skip_asset_checkboolean
start_datestring (date-time) | null
uristring | null
put /api/v2/assets/{asset_id}

Parameters

NameInTypeRequired
asset_idpathstringyes

Request body application/json

Schema: UpdateAssetSerializerV2

FieldTypeNotes
duration*integer
end_date*string (date-time)
is_enabled*boolean
is_processingboolean
name*string
nocacheboolean
play_orderinteger
skip_asset_checkboolean
start_date*string (date-time)

Responses

200

Schema: AssetSerializerV2

FieldTypeNotes
asset_id*stringread-only
durationinteger (int64) | null
end_datestring (date-time) | null
is_active*booleanread-only
is_enabledboolean
is_processingboolean
mimetypestring | null
namestring | null
nocacheboolean
play_orderinteger (int64)
skip_asset_checkboolean
start_datestring (date-time) | null
uristring | null
patch /api/v2/assets/{asset_id}

Parameters

NameInTypeRequired
asset_idpathstringyes

Request body application/json

Schema: PatchedUpdateAssetSerializerV2

FieldTypeNotes
durationinteger
end_datestring (date-time)
is_enabledboolean
is_processingboolean
namestring
nocacheboolean
play_orderinteger
skip_asset_checkboolean
start_datestring (date-time)

Responses

200

Schema: AssetSerializerV2

FieldTypeNotes
asset_id*stringread-only
durationinteger (int64) | null
end_datestring (date-time) | null
is_active*booleanread-only
is_enabledboolean
is_processingboolean
mimetypestring | null
namestring | null
nocacheboolean
play_orderinteger (int64)
skip_asset_checkboolean
start_datestring (date-time) | null
uristring | null
delete /api/v2/assets/{asset_id}

Parameters

NameInTypeRequired
asset_idpathstringyes

Responses

204 No response body
get /api/v2/assets/{asset_id}/content

The content of the asset. `type` can either be `file` or `url`. In case of a file, the fields `mimetype`, `filename`, and `content` will be present. In case of a URL, the field `url` will be present.

Parameters

NameInTypeRequired
asset_idpathstringyes

Responses

200
FieldTypeNotes
contentstring
filenamestring
mimetypestring
typestring
urlstring

backup

post /api/v2/backup

Create a backup of the current Anthias instance, which includes the following: * current settings * image and video assets * asset metadata (e.g. name, duration, play order, status), which is stored in a SQLite database

Responses

201

string

device settings

get /api/v2/device_settings

Responses

200

Schema: DeviceSettingsSerializerV2

FieldTypeNotes
audio_output*string
auth_backend*string
date_format*string
debug_logging*boolean
default_assets*boolean
default_duration*integer
default_streaming_duration*integer
player_name*string
show_splash*boolean
shuffle_playlist*boolean
use_24_hour_clock*boolean
username*string
patch /api/v2/device_settings

Request body application/json

Schema: PatchedUpdateDeviceSettingsSerializerV2

FieldTypeNotes
audio_outputstring
auth_backendany
current_passwordstring
date_formatstring
debug_loggingboolean
default_assetsboolean
default_durationinteger
default_streaming_durationinteger
passwordstring
password_2string
player_namestring
show_splashboolean
shuffle_playlistboolean
use_24_hour_clockboolean
usernamestring

Responses

200
FieldTypeNotes
messagestring
400
FieldTypeNotes
errorstring

file asset

post /api/v2/file_asset

Request body multipart/form-data

FieldTypeNotes
file_uploadstring (binary)

Responses

200
FieldTypeNotes
extstring
uristring

info

get /api/v2/info

Responses

200
FieldTypeNotes
anthias_versionstring
device_modelstring
display_power[string null]
free_spacestring
host_userstring
ip_addressesstring[]
loadavgnumber
mac_addressstring
memoryobject
up_to_dateboolean
uptimeobject
viewlogstring

integrations

get /api/v2/integrations

Responses

200

Schema: IntegrationsSerializerV2

FieldTypeNotes
balena_app_idstring | null
balena_app_namestring | null
balena_device_idstring | null
balena_device_name_at_initstring | null
balena_host_os_versionstring | null
balena_supervisor_versionstring | null
is_balena*boolean

reboot

post /api/v2/reboot

Responses

200 No response body

recover

post /api/v2/recover

Recover data from a backup file. The backup file must be a `.tar.gz` file.

Request body multipart/form-data

FieldTypeNotes
backup_uploadstring (binary)

Responses

200

string

shutdown

post /api/v2/shutdown

Responses

200 No response body