# Presigned R2 PUT for one xorb

`POST /v1/datasets/upload/prepare-object`

**Deprecated.**

Deprecated: only SDKs before 0.6.9 call this, and it is removed at the
date in its `Sunset` header. Use `POST /v1/datasets/upload/prepare-batch`,
which presigns every xorb of a file in one call, as the current SDK does.

Content-addressed presigned PUT URL. The customer PUTs the xorb bytes
straight to R2 with this URL — bytes never touch the gateway.

- Base URL: `https://junction-api.qualiastudios.dev`
- Authentication: an API key in the `X-API-Key` header, or `Authorization: Bearer …`

## Request body

Required: `application/json` `PrepareUploadBody`

## Responses

- `200` Successful Response: `application/json` `any`
- `401` Invalid or missing API key: `application/json` `ErrorResponse`
- `422` Validation Error: `application/json` `HTTPValidationError`

## Schemas

```yaml
PrepareUploadBody:
  properties:
    blob_id:
      type: string
      pattern: ^[0-9a-f]{64}$
    envelope_sha256:
      type: string
      pattern: ^[0-9a-f]{64}$
    content_length:
      type: integer
      minimum: 1
    ttl_seconds:
      type: integer
      maximum: 3600
      minimum: 60
      default: 300
  additionalProperties: false
  type: object
  required:
    - blob_id
    - envelope_sha256
    - content_length
  title: PrepareUploadBody
ErrorResponse:
  properties:
    detail:
      type: string
      description: Error message describing what went wrong
  type: object
  required:
    - detail
  title: ErrorResponse
  description: Standard error response.
HTTPValidationError:
  properties:
    detail:
      items:
        $ref: "#/components/schemas/ValidationError"
      type: array
  type: object
  title: HTTPValidationError
ValidationError:
  properties:
    loc:
      items:
        type:
          - string
          - integer
      type: array
      title: Location
    msg:
      type: string
      title: Message
    type:
      type: string
      title: Error Type
    input: {}
    ctx:
      type: object
      title: Context
  type: object
  required:
    - loc
    - msg
    - type
  title: ValidationError
```
