Skip to main content

Create image item using file from device

POST 

/v2/boards/:board_id_PlatformFileUpload/images

Adds an image item to a board by specifying a file from device.

Required scope

boards:write

Rate limiting

Level 2

Request

Path Parameters

    board_id_PlatformFileUpload stringrequired

    Unique identifier (ID) of the board where you want to create the item.

Body

required

    data

    object

    title string

    title for the document

    position

    object

    Contains information about the item's position on the board, such as its x coordinate, y coordinate, and the origin of the x and y coordinates.

    x double

    X-axis coordinate of the location of the item on the board. By default, all items have absolute positioning to the board, not the current viewport. Default: 0. The center point of the board has x: 0 and y: 0 coordinates.

    y double

    Y-axis coordinate of the location of the item on the board. By default, all items have absolute positioning to the board, not the current viewport. Default: 0. The center point of the board has x: 0 and y: 0 coordinates.

    geometry

    object

    Contains geometrical information about the item, such as its width or rotation. You can set either the width or height, you cannot set both the width and height at the same time.

    height double

    Height of the item, in pixels.

    width double

    Width of the item, in pixels.

    rotation double

    Rotation angle of an item, in degrees, relative to the board. You can rotate items clockwise (right) and counterclockwise (left) by specifying positive and negative values, respectively.

    parent

    object

    Contains information about the parent frame for the item.

    id int64

    Unique identifier (ID) of the parent frame for the item.

    resource binaryrequired

    Select a file to upload

Responses

Image item created

Schema

    id stringrequired

    Unique identifier (ID) of an item.

    data

    object

    imageUrl string

    The URL to download the resource. You must use your access token to access the URL. The URL contains the redirect parameter and the format parameter to control the request execution as described in the following parameters: format parameter: By default, the image format is set to the preview image. If you want to download the original image, set the format parameter in the URL to original. redirect: By default, the redirect parameter is set to false and the resource object containing the URL and the resource type is returned with a 200 OK HTTP code. This URL is valid for 60 seconds. You can use this URL to retrieve the resource file. If the redirect parameter is set to true, a 307 TEMPORARY_REDIRECT HTTP response is returned. If you follow HTTP 3xx responses as redirects, you will automatically be redirected to the resource file and the content type returned can be image/png, 'image/svg', or 'image/jpg', depending on the original image type.

    title string

    A short text header to identify the image.

    position

    object

    Contains location information about the item, such as its x coordinate, y coordinate, and the origin of the x and y coordinates.

    origin string

    Possible values: [center]

    Default value: center

    Area of the item that is referenced by its x and y coordinates. For example, an item with a center origin will have its x and y coordinates point to its center. The center point of the board has x: 0 and y: 0 coordinates. Currently, only one option is supported.

    relativeTo string

    Possible values: [canvas_center, parent_top_left]

    x double

    X-axis coordinate of the location of the item on the board. By default, all items have absolute positioning to the board, not the current viewport. Default: 0. The center point of the board has x: 0 and y: 0 coordinates.

    y double

    Y-axis coordinate of the location of the item on the board. By default, all items have absolute positioning to the board, not the current viewport. Default: 0. The center point of the board has x: 0 and y: 0 coordinates.

    geometry

    object

    Contains geometrical information about the item, such as its width or height.

    height double

    Height of the item, in pixels.

    rotation double

    Rotation angle of an item, in degrees, relative to the board. You can rotate items clockwise (right) and counterclockwise (left) by specifying positive and negative values, respectively.

    width double

    Width of the item, in pixels.

    createdAt date-time

    Date and time when the item was created.
    Format: UTC, adheres to ISO 8601, includes a trailing Z offset.

    createdBy

    object

    Contains information about the user who created the item.

    id string

    Unique identifier (ID) of the user.

    type string

    Indicates the type of object returned. In this case, type returns user.

    modifiedAt date-time

    Date and time when the item was last modified.
    Format: UTC, adheres to ISO 8601, includes a trailing Z offset.

    modifiedBy

    object

    Contains information about the user who last modified the item.

    id string

    Unique identifier (ID) of the user.

    type string

    Indicates the type of object returned. In this case, type returns user.

    parent

    object

    Contains information about the parent frame for the item.

    id int64

    Unique identifier (ID) of the parent frame for the item.

    links

    object

    Contains applicable links for the current object.

    self string

    Link to obtain more information about the current object.

    links

    object

    Contains applicable links for the item.

    related string

    Link to obtain information about the child items related to the frame.

    self string

    Link to obtain information about the current item.

    type stringrequired

    Type of item that is returned.

Loading...