### GET /effects Source: https://docs.picsart.io/picsart-image-tools-api Retrieves a list of supported effects. ```APIDOC ## GET /effects ### Description Retrieves a list of all supported effects available in the API. ### Method GET ### Endpoint /effects ### Parameters None ### Response #### Success Response (200) - **effects** (array of strings) - A list of available effect names. #### Response Example ```json { "effects": [ "effect1", "effect2" ] } ``` ``` -------------------------------- ### GET /websites/picsart_io/effects Source: https://docs.picsart.io/picsart-image-tools-api Retrieves a list of available effects from the Picsart IO API. Includes detailed information about rate limiting and credit availability in the response headers. ```APIDOC ## GET /websites/picsart_io/effects ### Description Retrieves a list of all available effects. The response includes status and a data array containing effect details. ### Method GET ### Endpoint /websites/picsart_io/effects ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **data** (array) - An array of effect objects. - **name** (string) - The name of the effect. - **status** (string) - The status of the response. #### Headers - **X-Picsart-Correlation-Id** (string) - The id which will help for troubleshooting request chain in the system. - **X-Picsart-Ratelimit-Available** (integer) - The number of available calls within the timeframe. - **X-Picsart-Ratelimit-Limit** (integer) - The total number of requests that can be done within the timeframe. - **X-Picsart-Ratelimit-Reset-Time** (integer) - The time when the used request count resets. - **X-Picsart-Credit-Available** (integer) - The remaining number of the credits on the balance. #### Response Example ```json { "data": [ { "name": "effect_name_1" }, { "name": "effect_name_2" } ], "status": "success" } ``` #### Error Responses - **400 Bad Request**: Invalid request. - **401 Unauthorized**: Authentication failed. - **402 Payment Required**: Insufficient credits. ``` -------------------------------- ### GET /effects/ai Source: https://docs.picsart.io/picsart-image-tools-api Retrieves a list of supported AI effects available through the API. ```APIDOC ## GET /effects/ai ### Description This service retrieves the list of supported AI effects. ### Method GET ### Endpoint /effects/ai ### Parameters None ### Request Example (No request body for GET requests) ### Response #### Success Response (200) - **effects** (array) - A list of available AI effect names. - **effect_name** (string) - The name of an AI effect. #### Response Example ```json { "effects": [ "effect1", "effect2" ] } ``` ``` -------------------------------- ### GET /balance Source: https://docs.picsart.io/picsart-image-tools-api Retrieves the current credits balance. Requires an API key for authorization. ```APIDOC ## GET /balance ### Description Check your balance of credits. ### Method GET ### Endpoint /balance ### Parameters #### Headers - **X-Picsart-API-Key** (string) - Required - Your API key. ### Request Example ```json { "example": "No request body needed for balance check." } ``` ### Response #### Success Response (200) - **balance** (integer) - The current credits balance. #### Response Example ```json { "balance": 100 } ``` ``` -------------------------------- ### Get Available Credits Source: https://docs.picsart.io/picsart-image-tools-api Retrieves the remaining number of credits available on your account balance. This endpoint is useful for monitoring your usage and ensuring you have sufficient credits for API operations. ```APIDOC ## GET /websites/picsart_io/credits ### Description Retrieves the remaining number of credits on the balance. ### Method GET ### Endpoint /websites/picsart_io/credits ### Parameters #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **X-Picsart-Credit-Available** (integer) - The remaining number of the credits on the balance. #### Response Example { "X-Picsart-Credit-Available": 1000 } #### Error Responses - **500 Internal Server Error**: An error occurred on the server. - **503 Service Unavailable**: The service is temporarily unavailable. ``` -------------------------------- ### Effects Previews Parameters Source: https://docs.picsart.io/picsart-image-tools-api Generate previews for multiple AI effects applied to an image. ```APIDOC ## POST /websites/picsart_io/effects_previews ### Description Generates previews of multiple AI effects applied to an image. ### Method POST ### Endpoint /websites/picsart_io/effects_previews ### Parameters #### Request Body - **effect_names** (array of strings) - Required - An array containing up to 10 effect names to generate previews for. Valid options include: 1972, apr1, apr2, apr3, blur, gblur, lensblur, motionblur, smartblur, pixelize, brl1, brnz1, brnz2, brnz3, brnz4, cyber1, cyber2, dodger, fattal2, food1, food2, icy1, icy2, icy3, light1, light2, light3, light4, light5, light6, light7, light8, light9, light10, light11, light12. ### Request Example ```json { "effect_names": [ "winterblues", "wispy", "geode" ] } ``` ### Response #### Success Response (200) - **previews** (object) - An object where keys are effect names and values are URLs to the effect previews. #### Response Example ```json { "previews": { "winterblues": "https://example.com/preview_winterblues.png", "wispy": "https://example.com/preview_wispy.png", "geode": "https://example.com/preview_geode.png" } } ``` ``` -------------------------------- ### POST /effects/previews Source: https://docs.picsart.io/picsart-image-tools-api Generates a preview (thumbnail) of an effect applied to an image. ```APIDOC ## POST /effects/previews ### Description Applies an effect to an input image and returns a preview (thumbnail) of the effect. ### Method POST ### Endpoint /effects/previews ### Parameters #### Request Body - **image** (file) - Required - The image file to generate a preview for. - **effect** (string) - Required - The name of the effect to apply for the preview. ### Request Example ```json { "image": "", "effect": "effect1" } ``` ### Response #### Success Response (200) - **result** (object) - Contains the preview image data. #### Response Example ```json { "result": { "url": "https://picsart.io/preview_image.jpg" } } ``` ``` -------------------------------- ### GET /upscale/ultra/{transaction_id} Source: https://docs.picsart.io/picsart-image-tools-api Retrieves the result of an ultra upscale transformation, typically used for asynchronously processed images. ```APIDOC ## GET /upscale/ultra/{transaction_id} ### Description Use this method, along with transaction_id, to retrieve the upscale ultra finished image if the transformation was done asynchronously. ### Method GET ### Endpoint /upscale/ultra/{transaction_id} #### Path Parameters - **transaction_id** (string) - Required - The ID returned from the POST method when it's done asynchronously. ### Response #### Success Response (200) - **image** (string) - The resulting upscaled image. #### Success Response (202) - **status** (string) - Indicates the processing is still ongoing. #### Error Responses - **400**: Bad Request - **401**: Unauthorized - **402**: Payment Required - **403**: Forbidden - **404**: Not Found - **405**: Method Not Allowed - **413**: Payload Too Large - **422**: Unprocessable Entity - **415**: Unsupported Media Type - **429**: Too Many Requests - **431**: Request Header Fields Too Large - **500**: Internal Server Error - **503**: Service Unavailable ``` -------------------------------- ### POST /masks/previews Source: https://docs.picsart.io/picsart-image-tools-api Applies mask effects to an input image and returns a thumbnail preview of the effect. ```APIDOC ## POST /masks/previews ### Description The masks previews service applies mask effects to a given input image and returns a preview (i.e., thumbnail) of the effect. ### Method POST ### Endpoint /masks/previews ### Parameters #### Request Body - **image_file** (file) - Required - The input image file. - **mask_file** (file) - Optional - The mask file to apply. - **mask_color** (string) - Optional - The color of the mask. ### Request Example ```json { "image_file": "", "mask_file": "", "mask_color": "#FF0000" } ``` ### Response #### Success Response (200) - **preview_image_url** (string) - URL to the preview image. #### Response Example ```json { "preview_image_url": "https://example.com/mask_preview.jpg" } ``` ``` -------------------------------- ### POST /background/pattern Source: https://docs.picsart.io/picsart-image-tools-api Generates a background texture pattern for an input image. Unlimited patterns can be created from the same source image. ```APIDOC ## POST /background/pattern ### Description The *pattern generator* tool generates a background texture pattern for the input image. You can create unlimited patterns from the same source image. ### Method POST ### Endpoint /background/pattern ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body This endpoint accepts `multipart/form-data` and includes schemas for `ImageParameters` and `TextureParameters`. ### Request Example (Example request body not provided in source) ### Response #### Success Response (200) (Response details not provided in source) #### Response Example (Example response body not provided in source) ``` -------------------------------- ### GET /design2replay/{transaction_id} Source: https://docs.picsart.io/picsart-image-tools-api Retrieves the result of a Design Import operation. Use the transaction ID obtained from the POST /design2replay request to fetch the status and the final converted file. ```APIDOC ## GET /design2replay/{transaction_id} ### Description Retrieves the result of a Design Import operation. Use the transaction ID obtained from the POST /design2replay request to fetch the status and the final converted file. ### Method GET ### Endpoint /design2replay/{transaction_id} ### Parameters #### Path Parameters - **transaction_id** (string) - Required - The ID returned from the POST /design2replay method. #### Query Parameters None #### Request Body None ### Request Example ``` GET /design2replay/1116b57cb-1999-4bfd-8c42-c739a006a111 ``` ### Response #### Success Response (200) - OK Returns the successful result of the design import operation, which may include the converted Replay file or a status update. #### Response Example ```json { "status": "completed", "result_url": "https://picsart.io/path/to/replay/file" } ``` #### Success Response (202) - Accepted Indicates that the request is still being processed. Check back later for the final result. #### Response Example ```json { "status": "processing" } ``` ``` -------------------------------- ### POST /describe - Image Description API Source: https://docs.picsart.io/picsart-image-tools-api Generate a detailed text description for a given image using the image-to-text functionality. Requires an API key for authorization. ```APIDOC ## POST /describe ### Description Generates a textual description of the content within an image, providing context and details. ### Method POST ### Endpoint /describe ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **image** (file) - Required - The image file to generate a description for. ### Request Example ```json { "image": "" } ``` ### Response #### Success Response (200) - **description** (string) - A detailed textual description of the image. #### Response Example ```json { "description": "A serene landscape with snow-capped mountains under a clear blue sky." } ``` ### Headers - **X-Picsart-API-Key** (string) - Required - Your API key for authentication. ``` -------------------------------- ### Image Background and Effects API Source: https://docs.picsart.io/picsart-image-tools-api This endpoint details parameters for manipulating image backgrounds, applying effects, and controlling output format. ```APIDOC ## POST /websites/picsart_io ### Description This endpoint allows for comprehensive image manipulation, including background customization, scaling, and the application of visual effects like strokes and shadows. ### Method POST ### Endpoint /websites/picsart_io ### Parameters #### Request Body - **bg_color** (string) - Optional - The background color. Can be a hex code (e.g., #82d5fa, #fff) or a color name (e.g., blue). Supports 4-/8-digit hexcodes for semi-transparency (e.g., #18d4ff87). If present, other `bg_` parameters must be empty. - **bg_blur** (integer) - Optional - Applies a blur effect to the background. Value must be between 0 and 100. - **bg_width** (integer) - Optional - Sets the background width in pixels. If not specified, the original width is maintained. - **bg_height** (integer) - Optional - Sets the background height in pixels. If not specified, the original height is maintained. - **scale** (string) - Optional - Controls how the image is scaled. Options: `fit` (longer side fits background), `fill` (shorter side fits background). Defaults to `fit`. - **auto_center** (boolean) - Optional - Automatically centers the object. Only applicable when `output_type=cutout`. Not recommended for partially visible objects. - **stroke_size** (integer) - Optional - Adds a solid stroke (border) around the cutout result. Value must be between 0 and 100. Set to 0 to remove the stroke. Works when `output_type=cutout`. - **stroke_color** (string) - Optional - Defines the color of the stroke. Can be a hex code (with or without '#') or a color name. Supports semi-transparency with 4-/8-digit hexcodes. Applied if `stroke_size` is 1 or above. - **stroke_opacity** (integer) - Optional - Defines the opacity of the stroke. Value must be between 0 and 100. Defaults to 100 (opaque). Works when `output_type=cutout` and `stroke_size` is 1 or above. - **shadow** (string) - Optional - Configures the shadow effect. Options: `disabled`, `custom`, `bottom-right`, `bottom`, `bottom-left`, `left`, `right`, `top-left`, `top`, `top-right`. Defaults to `disabled`. - **shadow_opacity** (integer) - Optional - Shadow opacity. Value must be between 0 and 100. Works when shadow is enabled. - **shadow_blur** (integer) - Optional - Shadow blur effect. Value must be between 0 and 100. Works when shadow is enabled. - **shadow_offset_x** (integer) - Optional - Horizontal offset for the shadow. Value must be between -100 and 100. Mandatory when `shadow=custom`. - **shadow_offset_y** (integer) - Optional - Vertical offset for the shadow. Value must be between -100 and 100. Mandatory when `shadow=custom`. - **format** (string) - Optional - Output image format. Options: `JPG`, `PNG`, `WEBP`. Defaults to `PNG`. #### Request Body (MasksParameters) - **mask** (object) - Required - Specifies mask-related parameters. - **format** (string) - Optional - Mask output format. Options: `JPG`, `PNG`, `WEBP`. Defaults to `PNG`. - **blend** (string) - Optional - Blend mode for the mask. Options: `normal`, `screen`, `overlay`, `multiply`, `darken`. ### Request Example ```json { "bg_color": "#82d5fa", "scale": "fill", "stroke_size": 5, "stroke_color": "#000000", "shadow": "bottom-right", "shadow_opacity": 50, "format": "JPG" } ``` ### Response #### Success Response (200) - **output_url** (string) - The URL of the processed image. #### Response Example ```json { "output_url": "https://example.com/processed_image.jpg" } ``` ``` -------------------------------- ### Texture Parameters Source: https://docs.picsart.io/picsart-image-tools-api This section outlines the parameters for applying textures to images. It includes options for format and width. ```APIDOC ## TextureParameters ### Description Parameters for applying textures to images. ### Parameters #### Request Body - **format** (string) - Optional - JPG/PNG/WEBP. Defaults to JPG. - **width** (integer) - Optional - The width of the texture. ``` -------------------------------- ### Laser Engraving Parameters Source: https://docs.picsart.io/picsart-image-tools-api Configure parameters for laser engraving, including colors and output format. ```APIDOC ## POST /websites/picsart_io/laser_engrave ### Description Applies laser engraving effects to an image with customizable parameters. ### Method POST ### Endpoint /websites/picsart_io/laser_engrave ### Parameters #### Request Body - **engrave_color** (string) - Optional - Can be a hexcolor code (e.g., #82d5fa, #fff) or a color name (e.g., blue). For semi-transparency, 4-/8-digit hexcodes are also supported (e.g., #18d4ff87). (If this parameter is present, the other bg_ parameters must be empty). Default: black - **background_color** (string) - Optional - Can be a hexcolor code (e.g., #82d5fa, #fff) or a color name (e.g., blue). For semi-transparency, 4-/8-digit hexcodes are also supported (e.g., #18d4ff87). (If this parameter is present, the other bg_ parameters must be empty). Default: white - **format** (string) - Optional - Output image format. Options are JPG, PNG, WEBP, SVG. Default: JPG ### Request Example ```json { "engrave_color": "#FF0000", "background_color": "#FFFFFF", "format": "PNG" } ``` ### Response #### Success Response (200) - **image_url** (string) - URL of the processed image. #### Response Example ```json { "image_url": "https://example.com/processed_image.png" } ``` ``` -------------------------------- ### Image Editing and Manipulation Source: https://docs.picsart.io/picsart-image-tools-api This section details parameters for image editing operations such as resizing, cropping, flipping, rotating, and perspective adjustments. It also covers options for setting image format and quality. ```APIDOC ## POST /websites/picsart_io ### Description This endpoint allows for advanced image editing and manipulation through various parameters. You can apply masks, stickers, enhance faces, and control editing modes like resize and crop. ### Method POST ### Endpoint /websites/picsart_io ### Parameters #### Request Body - **mask_id** (string) - Optional - Source mask ID of a mask previously uploaded to Picsart or result mask ID from a different API. (If this parameter is present, the other mask source parameters must be empty.) - **sticker** (string, binary) - Optional - Source sticker file (binary). (If this parameter is present, the other sticker source parameters must be empty.) - **sticker_url** (string) - Optional - Source sticker URL. (If this parameter is present, the other sticker source parameters must be empty.) - **sticker_id** (string) - Optional - Source sticker ID of a sticker previously uploaded to Picsart or result sticker ID from a different API. (If this parameter is present, the other sticker source parameters must be empty.) - **format** (string) - Optional - Optionally select one of the image formats (JPG is chosen if left blank). Options are: JPG, PNG, WEBP. Default: JPG. #### FaceEnhanceParameters - **format** (string) - Optional - Optionally select one of the image formats (JPG is the default). Options are: JPG, PNG, WEBP. Default: JPG. #### EditParameters - **format** (string) - Optional - Optionally select one of the image formats (JPG is chosen if left blank). Options are: JPG, PNG, WEBP. Default: JPG. - **mode** (string) - Optional - For *crop* mode, the outcome image will be center-cropped with the given size (width, height). For the *resize* mode, the smallest size will be fitted to preserve the original proportion of the image. When the outcome size is not provided with width and height, no cropping or resizing will be applied. Enum: resize, crop. - **size** (integer) - Optional - When defined, this parameter overrides and applies the value for both width and height. - **width** (integer) - Optional - Width of outcome image. If the provided width is larger than the original width of the file, the original size of the image will be selected. When crop size is defined, but the x,y starting position is not provided, the crop will be a center-crop. - **height** (integer) - Optional - Height of outcome image. If the provided height is larger than the original width of the file, the original size of the image will be selected. When crop size is defined, but the x,y starting position is not provided, the crop will be a center-crop. - **flip** (string) - Optional - Choose a way to flip the image. Enum: horizontal, vertical. - **rotate** (number) - Optional - Enter a float value to rotate the image from -180 to +180. Default: 0.0. - **perspective_horizontal** (integer) - Optional - The horizontal perspective after edits. Default: 0. Min: -45, Max: 45. - **perspective_vertical** (integer) - Optional - The vertical perspective after edits. Default: 0. Min: -45, Max: 45. - **quality** (integer) - Optional - This refers to the level of accuracy of the image processing. The greater the quality (i.e., the larger the number), the larger the image file size. Default: 90. Min: 10, Max: 100. #### OverlayParameters - **overlay_image** (string, binary) - Optional - Overlay image file (binary). (If this parameter is present, the other image source parameters must be empty.) This only has an effect when output=cutout. - **overlay_image_url** (string) - Optional - URL for overlay image. ### Request Example ```json { "sticker_url": "http://example.com/sticker.png", "EditParameters": { "mode": "resize", "width": 500, "height": 300, "rotate": 45.0, "quality": 85 } } ``` ### Response #### Success Response (200) - **output_image** (string) - URL of the processed image. #### Response Example ```json { "output_image": "http://example.com/processed_image.jpg" } ``` ``` -------------------------------- ### Masks Preview Parameters Source: https://docs.picsart.io/picsart-image-tools-api This section details the parameters available for generating mask previews. These parameters control the format, blending, mask type, opacity, hue, flip options, and preview size. ```APIDOC ## MasksPreviewParameters ### Description Parameters for generating mask previews. ### Parameters #### Request Body - **format** (string) - Optional - JPG/PNG/WEBP. Defaults to JPG. - **blend** (string) - Optional - Blending mode (normal, screen, overlay, multiply, darken, lighten, add). Defaults to screen. - **mask** (array of strings) - Required - Array of mask types (lace1, lace2, lace3, lace4, shdw2, shdw17, rpl3, rpl5, prsm3, prsm9, prsm10). Minimum 1 item. - **opacity** (integer) - Optional - Opacity level from 0 to 100. Defaults to 100. - **hue** (integer) - Optional - Hue adjustment from -180 to 180. Defaults to 0. - **mask_flip** (string) - Optional - Mask flip option (left, right, mirror horizontal, mirror vertical, turnaround). - **preview_size** (integer) - Optional - Maximum width or height for the preview image (max 240px). Defaults to 120px. ``` -------------------------------- ### POST /websites/picsart_io/enhance Source: https://docs.picsart.io/picsart-image-tools-api Applies specified effects and enhancements to an image. You can choose an upscale factor, an output format, and configure various effect parameters. ```APIDOC ## POST /websites/picsart_io/enhance ### Description Applies specified effects and enhancements to an image. You can choose an upscale factor, an output format, and configure various effect parameters. ### Method POST ### Endpoint `/websites/picsart_io/enhance` ### Parameters #### Request Body - **upscale_factor** (integer) - Optional - Choose one of the upscale factors. The options are 2, 4, 6, 8. - **effects_parameters** (object) - Required - Parameters for applying effects. - **effect_name** (string) - Required - Choose an effect from the dropdown menu. Available effects include: 1972, apr1, apr2, apr3, blur, gblur, lensblur, motionblur, smartblur, pixelize, brl1, brnz1, brnz2, brnz3, brnz4, cyber1, cyber2, dodger, fattal2, food1, food2, icy1, icy2, icy3, light1 through light20, mnch1, mnch2, mnch3, nature1, nature2, noise, ntrl1, ntrl2, popart, saturation, sft1, sft2, sft3, sft4, shadow1, shadow2, sketch1, sketch2, sketch3, sketcher1, sketcher2, spc1, tl1, tl2, urban1, urban2, water1, water2. - **fade** (integer) - Optional - Fade the effect. 0 means no fade and 100 means it's disabled. Note that some effects do not support fade. Defaults to 0. - **format** (string) - Optional - Optionally select one of the output image formats. Options are: JPG, PNG, WEBP. Defaults to JPG. ### Request Example ```json { "upscale_factor": 2, "effects_parameters": { "effect_name": "blur", "fade": 50, "format": "PNG" } } ``` ### Response #### Success Response (200) - **image_url** (string) - URL of the enhanced image. #### Response Example ```json { "image_url": "https://example.com/enhanced_image.png" } ``` ``` -------------------------------- ### Effects Previews API Source: https://docs.picsart.io/picsart-image-tools-api Retrieves previews of effects. This endpoint returns a list of effects with their associated URLs and names. ```APIDOC ## GET /websites/picsart_io/effects/previews ### Description Retrieves previews of effects, including their IDs, URLs, and names. ### Method GET ### Endpoint /websites/picsart_io/effects/previews ### Parameters #### Query Parameters (None specified) ### Request Example (No request body for GET request) ### Response #### Success Response (200) - **data** (array) - An array of effect preview objects. - **id** (string, nullable) - The ID of the effect. - **url** (string) - The URL of the effect preview. - **effect_name** (string) - The name of the effect. - **status** (string) - The status of the response. #### Headers - **X-Picsart-Correlation-Id** (string) - The ID for troubleshooting request chains. - **X-Picsart-Ratelimit-Available** (integer) - The number of available calls within the timeframe. - **X-Picsart-Ratelimit-Limit** (integer) - The total number of requests allowed within the timeframe. - **X-Picsart-Ratelimit-Reset-Time** (integer) - The time when the request count resets. - **X-Picsart-Credit-Available** (integer) - The remaining credits on the balance. #### Response Example ```json { "data": [ { "id": "effect123", "url": "https://picsart.io/effects/preview1.jpg", "effect_name": "Vintage" }, { "id": "effect456", "url": "https://picsart.io/effects/preview2.jpg", "effect_name": "Faded" } ], "status": "success" } ``` ``` -------------------------------- ### POST /surfacemap Source: https://docs.picsart.io/picsart-image-tools-api Applies a sticker onto a target image using a mask, creating a 'live-print-preview' effect by mapping the sticker to the texture and curves of the target image. ```APIDOC ## POST /surfacemap ### Description Applies a sticker onto a target image using a mask, creating a 'live-print-preview' effect by mapping the sticker to the texture and curves of the target image. ### Method POST ### Endpoint /surfacemap ### Parameters #### Query Parameters None #### Request Body - **target_image** (file) - Required - The base image onto which the sticker will be applied. - **sticker_image** (file) - Required - The image file to be used as the sticker. - **mask_image** (file) - Required - A mask defining how the sticker should conform to the target image's surface. ### Request Example ``` --boundary Content-Disposition: form-data; name="target_image"; filename="target.jpg" Content-Type: image/jpeg --boundary Content-Disposition: form-data; name="sticker_image"; filename="sticker.png" Content-Type: image/png --boundary Content-Disposition: form-data; name="mask_image"; filename="mask.png" Content-Type: image/png --boundary-- ``` ### Response #### Success Response (200) - OK Returns the image with the sticker applied according to the mask and surface map. #### Response Example ```json { "result_image_url": "https://picsart.io/path/to/surfacemap/result.jpg" } ``` ``` -------------------------------- ### POST /edit Source: https://docs.picsart.io/picsart-image-tools-api Applies basic image editing operations such as resize, crop, flip, rotate, and perspective manipulation to an input image. ```APIDOC ## POST /edit ### Description Applies basic image editing operations including resize, crop, flip, rotate, and perspective manipulation. ### Method POST ### Endpoint /edit ### Parameters #### Request Body - **image** (file) - Required - The input image file. - **operations** (object) - Required - An object defining the editing operations to apply. ### Request Example ```json { "example": "Request body for basic editing" } ``` ### Response #### Success Response (200) - **result** (object) - Details of the edited image. #### Response Example ```json { "example": "Response body for successful image editing" } ``` ``` -------------------------------- ### Image Vectorization Parameters Source: https://docs.picsart.io/picsart-image-tools-api Configure parameters for vectorizing images, including downscaling options. ```APIDOC ## POST /vectorize ### Description Applies vectorization to an image, with options to control downscaling. ### Method POST ### Endpoint /vectorize ### Parameters #### Request Body - **downscale_to** (integer) - Optional - Large images can be downscaled. Use -1 to turn off downscaling. Otherwise, the image is downscaled by 0.5 until max(width, height) < downscale_to. When downscale_to is disabled with -1, the image width and height should be less than 4000px. Default is 2048. ### Request Example ```json { "downscale_to": -1 } ``` ### Response #### Success Response (200) - **vectorizedImageUrl** (string) - URL of the vectorized image. #### Response Example ```json { "vectorizedImageUrl": "https://example.com/vectorized_image.png" } ``` ``` -------------------------------- ### Image Description API Source: https://docs.picsart.io/picsart-image-tools-api This endpoint provides a description for a given image. It returns a success status along with the description data. ```APIDOC ## POST /websites/picsart_io/image_description ### Description Provides a description for a given image. ### Method POST ### Endpoint /websites/picsart_io/image_description ### Parameters #### Request Body - **image** (file) - Required - The image file to describe. ### Request Example ```json { "image": "@/path/to/your/image.jpg" } ``` ### Response #### Success Response (200) - **data** (object) - Contains the image description. - **description** (string) - The generated description of the image. - **status** (string) - The status of the operation (e.g., "success"). #### Response Example ```json { "data": { "description": "A beautiful landscape with mountains and a lake." }, "status": "success" } ``` ### Headers - **X-Picsart-Correlation-Id** (string) - The id which will help for troubleshooting request chain in the system. - **X-Picsart-Ratelimit-Available** (integer) - The number of available calls within the timeframe. - **X-Picsart-Ratelimit-Limit** (integer) - The total number of requests that can be done within the timeframe. - **X-Picsart-Ratelimit-Reset-Time** (integer) - The time when the used request count resets. - **X-Picsart-Credit-Available** (integer) - The remaining number of the credits on the balance. ``` -------------------------------- ### POST /design2replay Source: https://docs.picsart.io/picsart-image-tools-api Converts design files (AI, SVG) into a Replay file format compatible with the Picsart SDK. This tool allows for the reuse of existing designs within the Picsart ecosystem. ```APIDOC ## POST /design2replay ### Description Converts design files (AI, SVG) into a Replay file format compatible with the Picsart SDK. This tool allows for the reuse of existing designs within the Picsart ecosystem. Supported Formats: * AI (Adobe Illustrator) * SVG (Scalable Vector Graphics) Requires an API key to be provided in the **X-Picsart-API-Key** request header. ### Method POST ### Endpoint /design2replay ### Parameters #### Query Parameters None #### Request Body - **file** (file) - Required - The design file to be converted. ### Request Example ``` --boundary Content-Disposition: form-data; name="file"; filename="example.svg" Content-Type: image/svg+xml ... --boundary-- ``` ### Response #### Success Response (202) - Accepted This response indicates that the request has been accepted for processing. The actual result will be available via the `/design2replay/{transaction_id}` endpoint. #### Response Example ```json { "transaction_id": "1116b57cb-1999-4bfd-8c42-c739a006a111" } ``` ``` -------------------------------- ### POST /upload Source: https://docs.picsart.io/picsart-image-tools-api Uploads an image for subsequent transformations. This service is beneficial when applying multiple transformations to an image, as it provides a transaction ID. Supported formats include JPG, PNG, TIFF, and WEBP. Images can be sourced via file upload or a URL. ```APIDOC ## POST /upload ### Description Upload an image for transformations. The service returns a transaction_id for repeated use. ### Method POST ### Endpoint /upload ### Parameters #### Headers - **X-Picsart-API-Key** (string) - Required - Your API key. #### Request Body - **image_file** (file) - Required - The image file to upload. - **image_url** (string) - Optional - URL of the image to upload. ### Request Example ```json { "example": "Request body for image upload" } ``` ### Response #### Success Response (200) - **transaction_id** (string) - The ID for the uploaded transaction. - **image_id** (string) - The ID of the uploaded image. #### Response Example ```json { "transaction_id": "some_transaction_id", "image_id": "some_image_id" } ``` ``` -------------------------------- ### Surface Map Generation Source: https://docs.picsart.io/picsart-image-tools-api Generate a surface map using a mask file, URL, or ID. ```APIDOC ## POST /surfacemap ### Description Generates a surface map using provided mask information. ### Method POST ### Endpoint /surfacemap ### Parameters #### Request Body - **mask** (binary) - Optional - Source mask file. (If this parameter is present, the other mask source parameters must be empty.) - **mask_url** (string) - Optional - Source mask URL. (If this parameter is present, the other mask source parameters must be empty.) MaxLength: 2083, MinLength: 1. - **mask_id** (string) - Optional - Source mask ID. (If this parameter is present, the other mask source parameters must be empty.) ### Request Example ```json { "mask_url": "https://example.com/masks/my_mask.png" } ``` ### Response #### Success Response (200) - **surfaceMapUrl** (string) - URL of the generated surface map. #### Response Example ```json { "surfaceMapUrl": "https://example.com/surfacemaps/generated_map.jpg" } ``` ``` -------------------------------- ### POST /effects Source: https://docs.picsart.io/picsart-image-tools-api Applies one or more effects to an image. ```APIDOC ## POST /effects ### Description Applies up to 24 different effects to a given image. ### Method POST ### Endpoint /effects ### Parameters #### Request Body - **image** (file) - Required - The image file to apply effects to. - **effects** (string) - Required - A comma-separated list of effect names to apply. ### Request Example ```json { "image": "", "effects": "effect1,effect2" } ``` ### Response #### Success Response (200) - **result** (object) - Contains details of the image with applied effects. #### Response Example ```json { "result": { "url": "https://picsart.io/processed_image.jpg" } } ``` ``` -------------------------------- ### POST /adjustments Source: https://docs.picsart.io/picsart-image-tools-api Applies adjustments and effects to an image. You can specify multiple effects and their parameters. ```APIDOC ## POST /adjustments ### Description Applies a set of adjustments and/or effects to an image. You can provide a list of effects to be applied sequentially. ### Method POST ### Endpoint /adjustments ### Parameters #### Request Body - **image_url** (string) - Required - The URL of the image to be processed. - **effects** (array) - Optional - A list of effects to apply. Each effect can have its own parameters. - **name** (string) - Required - The name of the effect to apply. See the available effects list. - **preview_size** (integer) - Optional - The width of the preview image. Max value is 240px. Default is 120px. - **fade** (integer) - Optional - Fade the effect. 0 means no fade and 100 means it's disabled. Note that some effects do not support fade. - **format** (string) - Optional - Image format (JPG, PNG, WEBP). Default is JPG. - **brightness** (integer) - Optional - Adjust brightness (-100 to 100). Default is 0. - **contrast** (integer) - Optional - Adjust contrast (-100 to 100). Default is 0. - **clarity** (integer) - Optional - Adjust clarity (-100 to 100). Default is 0. - **saturation** (integer) - Optional - Adjust saturation (-100 to 100). Default is 0. - **hue** (integer) - Optional - Adjust hue (-100 to 100). Default is 0. ### Request Example ```json { "image_url": "https://example.com/image.jpg", "effects": [ { "name": "blur", "preview_size": 200, "fade": 50 }, { "name": "light13" } ], "brightness": 10, "saturation": -15 } ``` ### Response #### Success Response (200) - **image_url** (string) - The URL of the processed image. #### Response Example ```json { "image_url": "https://example.com/processed_image.jpg" } ``` ``` -------------------------------- ### POST /tags - Image Tagging API Source: https://docs.picsart.io/picsart-image-tools-api Analyze an image and receive relevant hashtag suggestions based on its content. Requires an API key for authorization. ```APIDOC ## POST /tags ### Description Analyzes an image to generate relevant tags and hashtags for content identification and categorization. ### Method POST ### Endpoint /tags ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **image** (file) - Required - The image file to be analyzed for tags. ### Request Example ```json { "image": "" } ``` ### Response #### Success Response (200) - **tags** (array of strings) - A list of suggested tags or hashtags for the image. #### Response Example ```json { "tags": ["nature", "landscape", "mountains", "sunset"] } ``` ### Headers - **X-Picsart-API-Key** (string) - Required - Your API key for authentication. ```