---
title: "Upload Browser Context Profile state"
method: POST
path: "/v1/profiles/{profileId}/upload"
tags: ["Browser Context Profiles"]
---

# Upload Browser Context Profile state

`POST /v1/profiles/{profileId}/upload`

## Request

- Base URL: `https://agent.tinyfish.ai`
- URL: `https://agent.tinyfish.ai/v1/profiles/{profileId}/upload`
- Auth: API key in header `X-API-Key`

Upload Browser Context Profile state

## Path parameters

- `profileId` string, required: Browser Context Profile ID

## Request body

- object
  - `cookies` object[], required
    - `name` string, required
    - `value` string, required
    - `domain` string, required
    - `path` string
    - `httpOnly` boolean
    - `secure` boolean
    - `sameSite` 'Strict' | 'Lax' | 'None'
    - `expires` number
    - `sourceScheme` string
    - `sourcePort` number
    - `partitionKey` string, nullable
    - `priority` 'Low' | 'Medium' | 'High'
  - `localStorage` object[]
    - `origin` string, required
    - `items` object[], required
      - `name` string, required
      - `value` string, required
  - `sessionStorage` object[]
    - `origin` string, required
    - `items` object[], required
      - `name` string, required
      - `value` string, required

## Response `200`

Upload Browser Context Profile state succeeded.

- object
  - `domains_updated` string[], required
  - `domains_failed` string[], required
  - `cookie_count` integer, required
  - `domains_skipped` object, required
    - `cookies_skipped` string[], required
    - `local_storage_skipped` string[], required
    - `session_storage_skipped` string[], required
    - `blob_too_large` string[], required

## Other responses

- `400`: Upload body is invalid or exceeds limits.
- `401`: Unauthorized - Invalid or missing API key
- `404`: Browser Context Profile not found.
- `500`: Internal server error

---

[API](https://skmtc.dev/tinyfish/apis/tinyfish-web-agent-automation-api-2.md) · [All operations](https://skmtc.dev/tinyfish/apis/tinyfish-web-agent-automation-api-2/llms.txt) · [OpenAPI document](https://skmtc.dev/tinyfish/apis/tinyfish-web-agent-automation-api-2/revisions/c48ef855099d?raw)
