Docs

Start here

Read a project's usage

GET/v1/studio/projects/{project}/usageon https://api.auray.ai/v1

What a project's members made and spent, by member, model and day, for a member who may view usage.

What a project's members made and spent, by member, model and day, for a member who may view usage. The window is days in UTC, both ends counted, at most 366; left out, the thirty days to today. Takes a key holding studio:read (or studio:write, which reads too) — Account offers both unticked — or the desktop's own session key. Spends nothing.

#Authentication

Authorization: Bearer auray_sk_… — a key with the scope the route names.

#Request

#Path parameters

NameTypeRequiredDescription
projectstringyes

#Query parameters

NameTypeRequiredDescription
sincestringno
untilstringno
memberstringnoOne member's, by their membership id.
modelstringnoOne model's, by its address or id. 0 to 200 characters.

#Example request

curl https://api.auray.ai/v1/studio/projects/3f0c8a52-6a1d-4e8b-9c2d-7e5f4a3b2c1d/usage \
  -H "Authorization: Bearer $AURAY_API_KEY"

#Responses

#200 OK

OK.

FieldTypeRequiredDefaultDescription
objectstringyes—One of "usage".
project_idstringyes—
sincestringyes—
untilstringyes—
totalsobjectyes—
totals.generationsintegeryes—
totals.credits_spentintegeryes—
totals.membersintegeryes—
totals.modelsintegeryes—
by_memberobject[]yes—
by_member[].memberobjectyes—Somebody as a project shows them: their membership's id while they are in it and the public Community profile they chose — never an account or an address.
by_member[].member.member_idstringyes—May be null.
by_member[].member.namestringyes—May be null.
by_member[].member.handlestringyes—May be null.
by_member[].member.avatar_urlstringyes—A URL. May be null.
by_member[].member.leftbooleanyes—Gone from the project since; what they wrote stays, with their name.
by_member[].generationsintegeryes—
by_member[].credits_spentintegeryes—
by_member[].last_atstringyes—May be null.
by_modelobject[]yes—
by_model[].modelobjectyes—The model an item was made with: its address and id as GET /models lists it, and the name a person reads. All three are null for an upload.
by_model[].model.addressstringyes—May be null.
by_model[].model.idstringyes—May be null.
by_model[].model.labelstringyes—May be null.
by_model[].generationsintegeryes—
by_model[].credits_spentintegeryes—
by_dayobject[]yes—
by_day[].daystringyes—
by_day[].generationsintegeryes—
by_day[].credits_spentintegeryes—
storageobjectyes—The bytes the project keeps now, by where they came from.
storage.generationsintegeryes—
storage.uploadsintegeryes—
rowsobject[]yes—One line per member, model and day: what a usage export lists.
rows[].daystringyes—
rows[].memberobjectyes—Somebody as a project shows them: their membership's id while they are in it and the public Community profile they chose — never an account or an address.
rows[].member.member_idstringyes—May be null.
rows[].member.namestringyes—May be null.
rows[].member.handlestringyes—May be null.
rows[].member.avatar_urlstringyes—A URL. May be null.
rows[].member.leftbooleanyes—Gone from the project since; what they wrote stays, with their name.
rows[].productstringyes—One of "photo", "video", "music", "threed", "external", "director".
rows[].modelobjectyes—The model an item was made with: its address and id as GET /models lists it, and the name a person reads. All three are null for an upload.
rows[].model.addressstringyes—May be null.
rows[].model.idstringyes—May be null.
rows[].model.labelstringyes—May be null.
rows[].generationsintegeryes—
rows[].credits_spentintegeryes—
request_idstringno—Mirrored in the X-Request-Id header.

Headers:

HeaderDescription
RateLimit-LimitBurst capacity.
RateLimit-Remaining
RateLimit-ResetSeconds until refill.
X-RateLimit-Limit
X-RateLimit-Remaining
X-RateLimit-ResetUnix seconds. The X- spelling is what client libraries read.
X-Request-Id

#400 Bad Request

#401 Unauthorized

#403 Forbidden

#404 Not Found

#413 Payload Too Large

#429 Too Many Requests

#500 Internal Server Error

#503 Service Unavailable

#Status codes

StatusMeaning
200OK.
400Bad Request
401Unauthorized
403Forbidden
404Not Found
413Payload Too Large
429Too Many Requests
500Internal Server Error
503Service Unavailable

Every refusal names its code, and every code is explained at Errors.

Start typing to search every page of the documentation.

Up arrow Down arrow to moveEnter to openEscape to close