Skip to content

List library items

GET
/open/v1/image/list
curl --request GET \
--url 'https://api.harperharbor.com/open/v1/image/list?scope=all&kind=image&pageNum=1&pageSize=50&sort=newest' \
--header 'Authorization: Bearer <token>'

List locally hosted, account-owned stored media with pagination, folder and kind filters, optional filename search and ordering. External references are excluded. Harbor returns capabilities and has no moderationState field. Returns the account-fixed public UID libraryPrefix, including for an empty library; overwrite and relativePaths capabilities are true. fileName contains the authored relative path for named resources.

scope
string
default: all
Allowed values: all role folder unfiled

role requires roleId; folder requires folderId; unfiled = items in no folder.

roleId
string format: uuid

Required when scope=role.

folderId
string

Required when scope=folder.

kind
string
default: image
Allowed values: image video audio font code data all

Media kind filter. Absent = images only; all = no filter.

pageNum
integer
default: 1 >= 1

1-based page; <1 becomes 1.

pageSize
integer
default: 50 >= 1 <= 100

<1 or >100 becomes 50.

q
string
<= 200 characters

Harbor capability extension: literal filename substring search across the entire selected collection. Use only when capabilities.search is true.

sort
string
default: newest
Allowed values: newest oldest name size

Harbor capability extension: order before pagination; use a value advertised by capabilities.sorts.

Page.

Media typeapplication/json
object
code
required
integer
Allowed values: 0
data
required
object
total
required

Total items in the scope.

integer format: int64
imageList
required
Array<object>
object
id
required
integer format: int64
roleId
required

Attributed card id or empty.

string
imageUrl
required
string format: uri
kind
required
string
Allowed values: image video audio font code data
mimeType

Absent for legacy rows.

string
byteSize
required

0 for legacy rows.

integer format: int64
pixelWidth
required
integer
pixelHeight
required
integer
createTime

RFC3339; absent when unknown.

string format: date-time
fileName

File name for items stored under the library prefix; absent for older items with generated URLs.

string
quota
required

Max items per account (10000).

integer
usedBytes
required

Bytes used by items with byte accounting (0 if unavailable).

integer format: int64
byteQuota
required

Max bytes per account (524288000).

integer format: int64
libraryPrefix

Account-fixed library URL prefix without a trailing slash. HarperHarbor uses https:///u/. Combine it with / and the authored relative path, URL-encoding individual segments. Do not derive one provider prefix from another provider UID.

string
capabilities

Optional provider-reported resource capabilities. Absence means unknown, not unrestricted.

object
kinds
Array<string>
formats

Accepted MIME types.

Array<string>
maxFileBytes
integer format: int64
search
boolean
sorts
Array<string>
overwrite

Whether uploading to the same relative path replaces content while preserving its URL.

boolean
relativePaths

Supports relativePath uploads preserving authored folder names and directory structure. Do not flatten directories for providers lacking this capability.

boolean
moves

Renaming or moving a folder or file moves its path and URL; see POST /open/v1/image/move.

boolean
Example
{
"code": 0,
"data": {
"imageList": [
{
"kind": "image"
}
]
}
}

invalid_param — unknown scope/kind or missing roleId/folderId for the scope.

Media typeapplication/json
object
error
required

Error code (snake_case) or, for legacy handlers, a free-text/localized message.

string
message

Human-readable sentence. Present only on middleware errors and /me, /me/wallet.

string
retryable

Whether retrying may succeed. Present only on middleware errors, /me, /me/wallet and service/share routes.

boolean
required_context_tier

Only on a first-turn context_capacity_exceeded: the smallest context tier that fits the whole card with room to talk. Save it as context in player settings and resend. Absent when no tier fits.

integer
>= 1 <= 5
required_context_tokens

The token budget of required_context_tier for the selected model, for display.

integer
constant_lore_trim_fits

Only on a first-turn context_capacity_exceeded: whether saving trimConstantLore=true lets the card play at the current tier. Absent on mid-conversation capacity errors.

boolean
credits_needed

Only on insufficient_credits: the credits this turn needs before it can start. Absent when the refusal came without an estimate.

integer
credits_available

Only on insufficient_credits: the credits the wallet could set aside for it.

integer
Examplegenerated
{
"error": "example",
"message": "example",
"retryable": true,
"required_context_tier": 1,
"required_context_tokens": 1,
"constant_lore_trim_fits": true,
"credits_needed": 1,
"credits_available": 1
}

unauthorized.

Media typeapplication/json
object
error
required

Error code (snake_case) or, for legacy handlers, a free-text/localized message.

string
message

Human-readable sentence. Present only on middleware errors and /me, /me/wallet.

string
retryable

Whether retrying may succeed. Present only on middleware errors, /me, /me/wallet and service/share routes.

boolean
required_context_tier

Only on a first-turn context_capacity_exceeded: the smallest context tier that fits the whole card with room to talk. Save it as context in player settings and resend. Absent when no tier fits.

integer
>= 1 <= 5
required_context_tokens

The token budget of required_context_tier for the selected model, for display.

integer
constant_lore_trim_fits

Only on a first-turn context_capacity_exceeded: whether saving trimConstantLore=true lets the card play at the current tier. Absent on mid-conversation capacity errors.

boolean
credits_needed

Only on insufficient_credits: the credits this turn needs before it can start. Absent when the refusal came without an estimate.

integer
credits_available

Only on insufficient_credits: the credits the wallet could set aside for it.

integer
Examplegenerated
{
"error": "example",
"message": "example",
"retryable": true,
"required_context_tier": 1,
"required_context_tokens": 1,
"constant_lore_trim_fits": true,
"credits_needed": 1,
"credits_available": 1
}

generic_error.

Media typeapplication/json
object
error
required

Error code (snake_case) or, for legacy handlers, a free-text/localized message.

string
message

Human-readable sentence. Present only on middleware errors and /me, /me/wallet.

string
retryable

Whether retrying may succeed. Present only on middleware errors, /me, /me/wallet and service/share routes.

boolean
required_context_tier

Only on a first-turn context_capacity_exceeded: the smallest context tier that fits the whole card with room to talk. Save it as context in player settings and resend. Absent when no tier fits.

integer
>= 1 <= 5
required_context_tokens

The token budget of required_context_tier for the selected model, for display.

integer
constant_lore_trim_fits

Only on a first-turn context_capacity_exceeded: whether saving trimConstantLore=true lets the card play at the current tier. Absent on mid-conversation capacity errors.

boolean
credits_needed

Only on insufficient_credits: the credits this turn needs before it can start. Absent when the refusal came without an estimate.

integer
credits_available

Only on insufficient_credits: the credits the wallet could set aside for it.

integer
Examplegenerated
{
"error": "example",
"message": "example",
"retryable": true,
"required_context_tier": 1,
"required_context_tokens": 1,
"constant_lore_trim_fits": true,
"credits_needed": 1,
"credits_available": 1
}