{
    "openapi": "3.0.3",
    "info": {
        "title": "Stockzen API",
        "version": "1.3",
        "description": "Download original files and license certificates from premium stock platforms (Envato Elements, Storyblocks, Vecteezy, MotionArray, Flaticon, Magnific) through one key.\n\nDocs: https://stockzen.io/api",
        "termsOfService": "https://stockzen.io/tos",
        "contact": {
            "name": "Stockzen support",
            "email": "support@stockzen.io",
            "url": "https://app.stockzen.io/helpdesk"
        }
    },
    "servers": [
        {
            "url": "https://stockzen.io/api/v1"
        }
    ],
    "tags": [
        {
            "name": "Downloads"
        },
        {
            "name": "Account"
        },
        {
            "name": "Catalogue"
        }
    ],
    "security": [
        {
            "bearerAuth": []
        },
        {
            "apiKeyHeader": []
        }
    ],
    "paths": {
        "/me": {
            "get": {
                "tags": [
                    "Account"
                ],
                "summary": "Account and plan",
                "operationId": "getMe",
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Me"
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "Missing or invalid API key",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "Rate limited",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/usage": {
            "get": {
                "tags": [
                    "Account"
                ],
                "summary": "Today's allowance per downloader",
                "operationId": "getUsage",
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Usage"
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "Missing or invalid API key",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "No active plan",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "Rate limited",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/services": {
            "get": {
                "tags": [
                    "Catalogue"
                ],
                "summary": "Supported downloaders and their API availability",
                "operationId": "listServices",
                "security": [],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "services": {
                                            "type": "array",
                                            "items": {
                                                "$ref": "#/components/schemas/Service"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/status": {
            "get": {
                "tags": [
                    "Catalogue"
                ],
                "summary": "Live status and 7-day uptime",
                "operationId": "getStatus",
                "security": [],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Status"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/health": {
            "get": {
                "tags": [
                    "Catalogue"
                ],
                "summary": "Is a downloader up right now",
                "operationId": "getHealth",
                "security": [],
                "parameters": [
                    {
                        "name": "service",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "enum": [
                                "envato",
                                "storyblocks",
                                "vecteezy",
                                "motionarray",
                                "flaticon",
                                "freepik"
                            ],
                            "default": "envato"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Healthy",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Health"
                                }
                            }
                        }
                    },
                    "503": {
                        "description": "Down or unknown",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Health"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/resolve": {
            "get": {
                "tags": [
                    "Downloads"
                ],
                "summary": "Identify an item without spending a download",
                "operationId": "resolveItem",
                "description": "Returns the item id, type and title — and for Storyblocks / MotionArray / Flaticon / Magnific the qualities, formats or sizes you can request. Nothing is charged.",
                "parameters": [
                    {
                        "name": "url",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "format": "uri"
                        },
                        "example": "https://app.envato.com/photos/ecb1d5b6-f41c-4091-83b0-5940582a8985"
                    },
                    {
                        "name": "format",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Preselect a format so `next.body` carries it: MotionArray uhd | hd | original, or a Flaticon / Magnific format code"
                    },
                    {
                        "name": "size",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Flaticon PNG / GIF / MP4 only: pixel size (16 … 512)"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Resolved"
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "Missing or invalid API key",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "Link belongs to another listing (RapidAPI)",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "Invalid or unsupported URL",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "Rate limited",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "501": {
                        "description": "Service not available through the API yet",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "502": {
                        "description": "Upstream provider error",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/download": {
            "post": {
                "tags": [
                    "Downloads"
                ],
                "summary": "Get the original file (+ license) for an item",
                "operationId": "download",
                "description": "Send the item page URL; receive a signed 1-hour download link and, where the provider issues one, a license-certificate PDF link. Spends one download from your quota. Same as POST /downloads.",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/DownloadRequest"
                            },
                            "example": {
                                "url": "https://app.envato.com/photos/ecb1d5b6-f41c-4091-83b0-5940582a8985",
                                "license": true
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Created",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Download"
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "Missing or invalid API key",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "No active plan / not included in trial / link belongs to another listing",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "Invalid or unsupported URL, or unknown quality/format",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "Download quota or rate limit reached",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "501": {
                        "description": "Service not available through the API yet",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "502": {
                        "description": "Upstream provider error",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/downloads": {
            "post": {
                "tags": [
                    "Downloads"
                ],
                "summary": "Resolve an item URL into signed download and license links",
                "operationId": "createDownload",
                "description": "Spends one download from your allowance for that service. The returned links are valid for one hour and can be fetched more than once at no extra cost. POST /download is an alias.",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/DownloadRequest"
                            },
                            "example": {
                                "url": "https://app.envato.com/photos/ecb1d5b6-f41c-4091-83b0-5940582a8985",
                                "license": true
                            }
                        }
                    }
                },
                "responses": {
                    "201": {
                        "description": "Created",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Download"
                                }
                            }
                        }
                    },
                    "401": {
                        "description": "Missing or invalid API key",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "403": {
                        "description": "No active plan / not included in trial",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "422": {
                        "description": "Invalid or unsupported URL",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "Download limit or rate limit reached",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "501": {
                        "description": "Service not available through the API yet",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "502": {
                        "description": "Upstream provider error",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/files/{token}": {
            "get": {
                "tags": [
                    "Downloads"
                ],
                "summary": "Stream the file behind a signed link",
                "operationId": "getFile",
                "security": [],
                "parameters": [
                    {
                        "name": "token",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "The file (Content-Disposition: attachment)",
                        "content": {
                            "application/octet-stream": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    },
                    "410": {
                        "description": "Link expired",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "502": {
                        "description": "Upstream provider error",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/licenses/{token}": {
            "get": {
                "tags": [
                    "Downloads"
                ],
                "summary": "Stream the license certificate (PDF) behind a signed link",
                "operationId": "getLicense",
                "security": [],
                "parameters": [
                    {
                        "name": "token",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "PDF",
                        "content": {
                            "application/pdf": {
                                "schema": {
                                    "type": "string",
                                    "format": "binary"
                                }
                            }
                        }
                    },
                    "410": {
                        "description": "Link expired",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    },
                    "502": {
                        "description": "Upstream provider error",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Error"
                                }
                            }
                        }
                    }
                }
            }
        }
    },
    "components": {
        "securitySchemes": {
            "bearerAuth": {
                "type": "http",
                "scheme": "bearer",
                "bearerFormat": "sz_live_…"
            },
            "apiKeyHeader": {
                "type": "apiKey",
                "in": "header",
                "name": "X-API-Key"
            },
            "rapidApiKey": {
                "type": "apiKey",
                "in": "header",
                "name": "X-RapidAPI-Key",
                "description": "Injected by RapidAPI; subscribe to the API on RapidAPI Hub to get one."
            }
        },
        "schemas": {
            "Error": {
                "type": "object",
                "properties": {
                    "error": {
                        "type": "object",
                        "properties": {
                            "code": {
                                "type": "string",
                                "example": "limit_reached"
                            },
                            "message": {
                                "type": "string"
                            },
                            "status": {
                                "type": "integer"
                            },
                            "service": {
                                "type": "string"
                            },
                            "retry_after": {
                                "type": "integer"
                            },
                            "resets_at": {
                                "type": "string",
                                "format": "date-time"
                            }
                        }
                    },
                    "docs": {
                        "type": "string",
                        "format": "uri"
                    }
                }
            },
            "Me": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "integer"
                    },
                    "login": {
                        "type": "string"
                    },
                    "email": {
                        "type": "string"
                    },
                    "name": {
                        "type": "string"
                    },
                    "plan": {
                        "type": "object",
                        "properties": {
                            "type": {
                                "type": "string",
                                "enum": [
                                    "trial",
                                    "monthly",
                                    "yearly",
                                    "individual",
                                    "none",
                                    "rapidapi"
                                ]
                            },
                            "active": {
                                "type": "boolean"
                            },
                            "product_ids": {
                                "type": "array",
                                "items": {
                                    "type": "integer"
                                }
                            },
                            "upgrade": {
                                "type": "string"
                            },
                            "rapidapi": {
                                "$ref": "#/components/schemas/RapidPlan"
                            }
                        }
                    },
                    "usage": {
                        "type": "object",
                        "description": "RapidAPI subscribers only",
                        "nullable": true
                    },
                    "api_key": {
                        "type": "object",
                        "nullable": true,
                        "properties": {
                            "prefix": {
                                "type": "string"
                            },
                            "label": {
                                "type": "string"
                            },
                            "created_at": {
                                "type": "string",
                                "format": "date-time"
                            }
                        }
                    },
                    "auth": {
                        "type": "string",
                        "enum": [
                            "key",
                            "rapidapi"
                        ]
                    },
                    "rate_limit": {
                        "type": "object",
                        "properties": {
                            "per_minute": {
                                "type": "integer"
                            },
                            "remaining": {
                                "type": "integer"
                            },
                            "resets_at": {
                                "type": "string",
                                "format": "date-time"
                            }
                        }
                    }
                }
            },
            "UsageRow": {
                "type": "object",
                "properties": {
                    "service": {
                        "type": "string",
                        "enum": [
                            "envato",
                            "storyblocks",
                            "vecteezy",
                            "motionarray",
                            "flaticon",
                            "freepik"
                        ]
                    },
                    "name": {
                        "type": "string"
                    },
                    "limit": {
                        "type": "integer"
                    },
                    "used": {
                        "type": "integer"
                    },
                    "remaining": {
                        "type": "integer"
                    },
                    "period": {
                        "type": "string",
                        "enum": [
                            "daily",
                            "lifetime"
                        ]
                    },
                    "resets_at": {
                        "type": "string",
                        "format": "date-time",
                        "nullable": true
                    },
                    "locked": {
                        "type": "string",
                        "nullable": true,
                        "enum": [
                            "under_development",
                            "not_included_in_trial",
                            "other_listing",
                            null
                        ],
                        "description": "Why the allowance is 0: the downloader is still under development, not part of the trial, or (RapidAPI) served by another listing"
                    },
                    "rapidapi": {
                        "type": "string",
                        "format": "uri",
                        "nullable": true,
                        "description": "RapidAPI only: listing that serves this downloader when locked = other_listing"
                    }
                }
            },
            "Usage": {
                "type": "object",
                "properties": {
                    "plan": {
                        "type": "string",
                        "enum": [
                            "trial",
                            "monthly",
                            "yearly",
                            "individual",
                            "rapidapi"
                        ]
                    },
                    "period": {
                        "type": "string",
                        "enum": [
                            "daily",
                            "lifetime",
                            "monthly"
                        ]
                    },
                    "resets_at": {
                        "type": "string",
                        "format": "date-time",
                        "nullable": true
                    },
                    "timezone": {
                        "type": "string"
                    },
                    "service": {
                        "type": "string",
                        "description": "RapidAPI only: the listing's downloader"
                    },
                    "rapidapi": {
                        "$ref": "#/components/schemas/RapidPlan"
                    },
                    "services": {
                        "type": "array",
                        "items": {
                            "$ref": "#/components/schemas/UsageRow"
                        }
                    }
                }
            },
            "Service": {
                "type": "object",
                "properties": {
                    "key": {
                        "type": "string",
                        "enum": [
                            "envato",
                            "storyblocks",
                            "vecteezy",
                            "motionarray",
                            "flaticon",
                            "freepik"
                        ]
                    },
                    "name": {
                        "type": "string"
                    },
                    "api": {
                        "type": "string",
                        "enum": [
                            "available",
                            "coming_soon",
                            "development"
                        ]
                    },
                    "telegram_bot": {
                        "type": "boolean",
                        "description": "Delivered by the Stockzen Telegram bot (independent of the REST API state)."
                    },
                    "license_certificates": {
                        "type": "boolean"
                    },
                    "license_note": {
                        "type": "string",
                        "nullable": true
                    },
                    "accepted_hosts": {
                        "type": "array",
                        "items": {
                            "type": "string"
                        }
                    },
                    "example_url": {
                        "type": "string"
                    },
                    "options": {
                        "type": "object",
                        "description": "Extra POST /downloads fields this service understands (name → description)",
                        "additionalProperties": {
                            "type": "string"
                        }
                    },
                    "web_downloader": {
                        "type": "string",
                        "format": "uri"
                    },
                    "rapidapi": {
                        "type": "string",
                        "format": "uri",
                        "nullable": true,
                        "description": "RapidAPI listing for this downloader"
                    }
                }
            },
            "Variant": {
                "type": "object",
                "description": "A quality/format the item is available in",
                "properties": {
                    "code": {
                        "type": "string",
                        "example": "4KMP4"
                    },
                    "label": {
                        "type": "string",
                        "example": "4K (MP4)"
                    },
                    "extension": {
                        "type": "string",
                        "nullable": true
                    },
                    "sized": {
                        "type": "boolean",
                        "description": "Flaticon: this format takes a `size`"
                    },
                    "note": {
                        "type": "string",
                        "nullable": true,
                        "description": "Magnific: dimensions / file note"
                    },
                    "width": {
                        "type": "integer",
                        "nullable": true,
                        "description": "Magnific photos"
                    },
                    "height": {
                        "type": "integer",
                        "nullable": true
                    }
                }
            },
            "Status": {
                "type": "object",
                "properties": {
                    "overall": {
                        "type": "string",
                        "enum": [
                            "operational",
                            "degraded",
                            "outage",
                            "unknown"
                        ]
                    },
                    "checked_at": {
                        "type": "string",
                        "format": "date-time",
                        "nullable": true
                    },
                    "services": {
                        "type": "array",
                        "items": {
                            "type": "object",
                            "properties": {
                                "key": {
                                    "type": "string"
                                },
                                "name": {
                                    "type": "string"
                                },
                                "state": {
                                    "type": "string",
                                    "enum": [
                                        "operational",
                                        "slow",
                                        "down",
                                        "unknown",
                                        "under_development"
                                    ]
                                },
                                "uptime_7d": {
                                    "type": "number",
                                    "nullable": true
                                },
                                "avg_response_ms": {
                                    "type": "integer",
                                    "nullable": true
                                },
                                "last_check": {
                                    "type": "string",
                                    "format": "date-time",
                                    "nullable": true
                                }
                            }
                        }
                    },
                    "page": {
                        "type": "string",
                        "format": "uri"
                    }
                }
            },
            "RapidPlan": {
                "type": "object",
                "properties": {
                    "key": {
                        "type": "string",
                        "enum": [
                            "BASIC",
                            "PRO",
                            "ULTRA",
                            "MEGA"
                        ]
                    },
                    "name": {
                        "type": "string"
                    },
                    "price_usd_month": {
                        "type": "number"
                    },
                    "quota": {
                        "type": "integer"
                    },
                    "period": {
                        "type": "string",
                        "enum": [
                            "daily",
                            "monthly"
                        ]
                    },
                    "overage_usd": {
                        "type": "number",
                        "nullable": true
                    },
                    "hard_limit": {
                        "type": "boolean"
                    },
                    "rate_limit_per_minute": {
                        "type": "integer"
                    },
                    "features": {
                        "type": "array",
                        "items": {
                            "type": "string"
                        }
                    },
                    "upgrade": {
                        "type": "string",
                        "format": "uri"
                    }
                }
            },
            "Health": {
                "type": "object",
                "properties": {
                    "ok": {
                        "type": "boolean"
                    },
                    "service": {
                        "type": "string",
                        "example": "envato"
                    },
                    "state": {
                        "type": "string",
                        "enum": [
                            "operational",
                            "slow",
                            "down",
                            "unknown"
                        ]
                    },
                    "session": {
                        "type": "string",
                        "enum": [
                            "valid",
                            "invalid_or_unreachable",
                            "unknown"
                        ]
                    },
                    "response_ms": {
                        "type": "integer",
                        "nullable": true
                    },
                    "uptime_7d": {
                        "type": "number",
                        "nullable": true
                    },
                    "checked_at": {
                        "type": "string",
                        "format": "date-time",
                        "nullable": true
                    },
                    "status_page": {
                        "type": "string",
                        "format": "uri"
                    }
                }
            },
            "Resolved": {
                "type": "object",
                "properties": {
                    "service": {
                        "type": "string",
                        "enum": [
                            "envato",
                            "storyblocks",
                            "vecteezy",
                            "motionarray",
                            "flaticon",
                            "freepik"
                        ]
                    },
                    "item": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string",
                                "description": "Provider item id (Envato: UUID; Storyblocks / MotionArray / Vecteezy: numeric)"
                            },
                            "type": {
                                "type": "string",
                                "example": "photos"
                            },
                            "title": {
                                "type": "string",
                                "nullable": true
                            },
                            "filename": {
                                "type": "string",
                                "nullable": true
                            },
                            "size": {
                                "type": "integer",
                                "nullable": true
                            },
                            "legacy_id": {
                                "type": "string",
                                "nullable": true,
                                "description": "Envato: the old elements.envato.com short id"
                            },
                            "variants": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/Variant"
                                },
                                "description": "Storyblocks: qualities you can pass as `quality`"
                            },
                            "default_quality": {
                                "type": "string",
                                "description": "Storyblocks"
                            },
                            "formats": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/Variant"
                                },
                                "description": "MotionArray footage, Flaticon, Magnific: formats you can pass as `format`"
                            },
                            "default_format": {
                                "type": "string",
                                "nullable": true,
                                "description": "MotionArray / Flaticon / Magnific"
                            },
                            "sizes": {
                                "type": "array",
                                "nullable": true,
                                "items": {
                                    "type": "string"
                                },
                                "description": "Flaticon icons: pixel sizes you can pass as `size` for png / gif / mp4"
                            },
                            "default_size": {
                                "type": "string",
                                "nullable": true,
                                "description": "Flaticon"
                            },
                            "pack": {
                                "type": "object",
                                "nullable": true,
                                "description": "Flaticon icon: the pack it belongs to",
                                "properties": {
                                    "id": {
                                        "type": "string"
                                    },
                                    "name": {
                                        "type": "string"
                                    }
                                }
                            },
                            "author": {
                                "type": "string",
                                "nullable": true,
                                "description": "Flaticon"
                            },
                            "premium": {
                                "type": "boolean",
                                "description": "Flaticon"
                            },
                            "items": {
                                "type": "integer",
                                "description": "Flaticon pack: number of icons"
                            },
                            "preview_url": {
                                "type": "string",
                                "format": "uri",
                                "nullable": true,
                                "description": "Flaticon / Magnific: preview image"
                            },
                            "slug": {
                                "type": "string",
                                "description": "Vecteezy"
                            },
                            "source_url": {
                                "type": "string",
                                "format": "uri"
                            },
                            "canonical_url": {
                                "type": "string",
                                "format": "uri"
                            }
                        }
                    },
                    "downloadable": {
                        "type": "boolean"
                    },
                    "charged": {
                        "type": "boolean",
                        "example": false
                    },
                    "next": {
                        "type": "object",
                        "description": "The POST /download call to make",
                        "properties": {
                            "method": {
                                "type": "string"
                            },
                            "url": {
                                "type": "string",
                                "format": "uri"
                            },
                            "body": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "DownloadRequest": {
                "type": "object",
                "required": [
                    "url"
                ],
                "properties": {
                    "url": {
                        "type": "string",
                        "format": "uri",
                        "description": "The item page URL on the provider site",
                        "example": "https://app.envato.com/photos/ecb1d5b6-f41c-4091-83b0-5940582a8985"
                    },
                    "license": {
                        "type": "boolean",
                        "default": true,
                        "description": "Also return a license certificate link (paid plans; providers that issue one)"
                    },
                    "licensee": {
                        "type": "string",
                        "maxLength": 80,
                        "description": "Envato / Magnific: name printed on the license certificate. Defaults to your account name (RapidAPI: your RapidAPI username)."
                    },
                    "quality": {
                        "type": "string",
                        "description": "Storyblocks: a variant code from GET /resolve (e.g. 4KMP4, HDMP4, WAV, MP3, PNG, JPG). Default: best available.",
                        "example": "4KMP4"
                    },
                    "format": {
                        "type": "string",
                        "description": "A format code from GET /resolve (item.formats[].code). MotionArray footage: uhd (default) | hd | original. Flaticon icons: svg (default) | png | eps | psd, animated icons also aep | lottie | gif | mp4; packs and icon fonts are always zip. Magnific: zip (default) | ai | eps | svg | psd | png for vectors/PSD, small | medium | large | original (default) for photos, 1080p-mp4 | 4k-mov … for video. Unknown codes → 422 invalid_format.",
                        "example": "svg"
                    },
                    "size": {
                        "type": "string",
                        "description": "Flaticon PNG / GIF / MP4 icons only: pixel size from GET /resolve (16, 24, 32, 64, 128, 256, 512). Default 512.",
                        "example": "512"
                    }
                }
            },
            "Download": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "string",
                        "example": "dl_3f9a1c2b7d4e"
                    },
                    "service": {
                        "type": "string",
                        "enum": [
                            "envato",
                            "storyblocks",
                            "vecteezy",
                            "motionarray",
                            "flaticon",
                            "freepik"
                        ]
                    },
                    "item": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "type": {
                                "type": "string"
                            },
                            "title": {
                                "type": "string",
                                "nullable": true
                            },
                            "filename": {
                                "type": "string"
                            },
                            "size": {
                                "type": "integer",
                                "nullable": true,
                                "description": "bytes (0 when the provider does not announce it; null for Flaticon / Magnific, which are resolved when download.url is fetched)"
                            },
                            "content_type": {
                                "type": "string"
                            },
                            "quality": {
                                "type": "string",
                                "description": "Storyblocks: the variant delivered"
                            },
                            "quality_label": {
                                "type": "string"
                            },
                            "variants": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/Variant"
                                }
                            },
                            "format": {
                                "type": "string",
                                "nullable": true,
                                "description": "MotionArray footage / Flaticon / Magnific: the format delivered"
                            },
                            "format_label": {
                                "type": "string",
                                "description": "Magnific"
                            },
                            "formats": {
                                "type": "array",
                                "items": {
                                    "$ref": "#/components/schemas/Variant"
                                }
                            },
                            "pixel_size": {
                                "type": "integer",
                                "nullable": true,
                                "description": "Flaticon PNG / GIF / MP4: the size delivered"
                            },
                            "width": {
                                "type": "integer",
                                "nullable": true,
                                "description": "Magnific photos: delivered dimensions"
                            },
                            "height": {
                                "type": "integer",
                                "nullable": true
                            },
                            "pack": {
                                "type": "object",
                                "nullable": true,
                                "properties": {
                                    "id": {
                                        "type": "string"
                                    },
                                    "name": {
                                        "type": "string"
                                    }
                                }
                            },
                            "preview_url": {
                                "type": "string",
                                "format": "uri",
                                "nullable": true
                            },
                            "slug": {
                                "type": "string",
                                "description": "Vecteezy"
                            },
                            "source_url": {
                                "type": "string",
                                "format": "uri"
                            }
                        }
                    },
                    "download": {
                        "type": "object",
                        "properties": {
                            "url": {
                                "type": "string",
                                "format": "uri",
                                "description": "Signed Stockzen link, valid 1 hour, re-fetchable"
                            },
                            "method": {
                                "type": "string"
                            },
                            "expires_at": {
                                "type": "string",
                                "format": "date-time"
                            },
                            "direct_url": {
                                "type": "string",
                                "format": "uri",
                                "nullable": true,
                                "description": "Envato only: Envato's own signed CDN link (fastest, ~10 minutes). Null for other providers."
                            },
                            "direct_expires_at": {
                                "type": "string",
                                "format": "date-time",
                                "nullable": true
                            }
                        }
                    },
                    "license": {
                        "type": "object",
                        "nullable": true,
                        "description": "Null when the provider bundles the license or on trial plans (see license_note)",
                        "properties": {
                            "url": {
                                "type": "string",
                                "format": "uri"
                            },
                            "format": {
                                "type": "string"
                            },
                            "licensee": {
                                "type": "string",
                                "nullable": true
                            },
                            "filename": {
                                "type": "string",
                                "nullable": true
                            },
                            "expires_at": {
                                "type": "string",
                                "format": "date-time"
                            }
                        }
                    },
                    "license_note": {
                        "type": "string",
                        "nullable": true
                    },
                    "usage": {
                        "$ref": "#/components/schemas/UsageRow"
                    }
                }
            }
        }
    }
}
