acyka api

POST /api/v1/collections

createCollection

needs lists:write

curl https://api.acyka.cc/api/v1/collections \
  -X POST \
  -H "Authorization: Bearer $ACYKA_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ }'

Asking #

The body

CollectionBody, sent as JSON. Every field it has is under the shapes below.

Answering #

201 Collection

The shapes #

Collection #

A shelf somebody named.

fieldtypewhat it is
code string
name string
about string
icon string
hue may be absentnumber | undefined
visibility string`public` | `unlisted` | `private`
shared booleanwhether anyone who can read it may also add to it
count number
saves number
owner string
owner_avatar may be absentstring | undefined
owner_verified boolean
covers string[]
at string
edited string

CollectionBody #

fieldtypewhat it is
name string
about may be absentstring | undefined
icon may be absentstring | undefined
hue may be absentnumber | undefined
visibility may be absentstring | undefined
shared may be absentboolean | undefined

When it says no #

A refusal is { "message": "errors.something" } — a phrase name and never a sentence, because one screen can be read in five languages. Every library turns the name into a type, so you catch the class you can do something about. Errors has the list.