> ## Documentation Index
> Fetch the complete documentation index at: https://hub.hcompany.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Initiate a profile upload

> Get a presigned URL to upload a browser profile archive.

Starts the [profile upload flow](/computer-use-agents/browser/profiles#uploading-a-profile).
Returns a presigned upload target so you can send the profile archive **directly to object
storage**, and the bytes never pass through the Agent API. No request body is required.

After uploading the archive, call
[Complete upload](/computer-use-agents/browser-profiles/complete-upload) with the returned
`profile_id` to finalize the profile.

**Returns** `200` with the presigned upload target.

`upload_url` and `upload_fields` are passed through from object storage unchanged, so send them exactly as returned, with the file as the last form field. They expire after `upload_expires_in` seconds.

***

## Response

<ResponseField name="profile_id" type="string">
  Id (UUID) reserved for the profile. Pass it to [Complete upload](/computer-use-agents/browser-profiles/complete-upload).
</ResponseField>

<ResponseField name="upload_url" type="string">
  Presigned object-storage URL to `POST` the archive to.
</ResponseField>

<ResponseField name="upload_fields" type="object">
  Form fields that must accompany the upload, sent before the file as `multipart/form-data`.
</ResponseField>

<ResponseField name="upload_expires_in" type="integer">
  Seconds until the presigned target expires.
</ResponseField>

***

## Examples

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST https://agp.eu.hcompany.ai/api/v2/browser-profiles/initiate-upload \
    -H "Authorization: Bearer $HAI_API_KEY"
  ```

  ```python Python theme={null}
  from hai_agents import Client

  client = Client()

  upload = client.browser_profiles.initiate_browser_profile_upload()
  print(upload.profile_id, upload.upload_url)
  ```

  ```typescript TypeScript theme={null}
  import { HaiAgentsClient } from "hai-agents";

  const client = new HaiAgentsClient();

  const upload = await client.browserProfiles.initiateBrowserProfileUpload();
  console.log(upload.profileId, upload.uploadUrl);
  ```
</CodeGroup>

```json Response theme={null}
{
  "profile_id": "a1b2c3d4-5678-90ab-cdef-1234567890ab",
  "upload_url": "https://storage.eu.hcompany.ai/browser-profiles",
  "upload_fields": {
    "key": "browser-profiles/pending/org_123/a1b2c3d4-5678-90ab-cdef-1234567890ab/profile.zip",
    "Content-Type": "application/zip",
    "x-amz-checksum-algorithm": "SHA256",
    "tagging": "<Tagging><TagSet><Tag><Key>status</Key><Value>pending</Value></Tag></TagSet></Tagging>",
    "bucket": "browser-profiles",
    "policy": "eyJ...",
    "x-amz-algorithm": "AWS4-HMAC-SHA256",
    "x-amz-credential": "AKIA.../20260206/eu-west-1/s3/aws4_request",
    "x-amz-date": "20260206T000000Z",
    "x-amz-signature": "abcd1234"
  },
  "upload_expires_in": 3600
}
```
