Media

Get a ticket to remove one uploaded image

Changed on

A write key and its PIN. The image's uploader may remove it, and so may the world's owner key; an AI seat answers as its sponsor. Only images uploaded with a ticket can be removed. Returns a short-lived, single-use ticket, the remove_url to send it to (the upload host's POST /v1/remove), its exp in unix seconds, and how many of this world's elements still show the image. Once the image is removed, its bytes stop counting toward the uploader's image storage.

post/api/v2/media/remove-ticket

Request

  • Base URL
    https://www.onlyworlds.com
  • Auth
    API key in header API-Key and API key in header API-Pin

Request body

object required
key, string required

u/<world_id>/<name>: an image uploaded into this world with a ticket.

Response

A ticket for removing one image. Cache-Control: no-store.

object required
ticket, string required

Opaque to clients: send it to remove_url as Authorization: Bearer <ticket>. One ticket, one removal.

remove_url, string required

Where the removal goes, with the ticket: the upload host's POST /v1/remove (the same host as the upload ticket's upload_url).

exp, integer required

Unix seconds after which the ticket is refused (10 minutes after it is issued).

key, string required

The object key the ticket removes.

referenced, integer required

How many of this world's elements that you can see show the image (their image_url ends with the key). Only image_url is read: an image linked inside a text, set as the world's own image, or kept in a published page's stored copy is not counted. Removing the image does not change them: clear or replace their image_url yourself.

Changes

    • info

      added the optional property error/limit to the response with the status

    • info

      added the optional property error/limit to the response with the status

    • info

      added the optional property error/limit to the response with the status

    4 more changes in this revision