> For the complete documentation index, see [llms.txt](https://bogdanfinn.gitbook.io/open-source-oasis/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://bogdanfinn.gitbook.io/open-source-oasis/shared-library/payload.md).

# Payload

This page shows once the full possible request payload against the shared library, with all default values.

#### Basic Request Input

```
{
  "catchPanics": false,
  "certificatePinningHosts": null,
  "customTlsClient": null,
  "transportOptions": null,
  "followRedirects": false,
  "forceHttp1": false,
  "disableHttp3": false,
  "disableSessionTickets": false,
  "withProtocolRacing": false,
  "headerOrder": null,
  "headers": null,
  "insecureSkipVerify": false,
  "isByteRequest": false,
  "isByteResponse": false,
  "isRotatingProxy": false,
  "proxyUrl": null,
  "requestBody": null,
  "requestCookies": null,
  "requestHostOverride": null,
  "defaultHeaders": null,
  "connectHeaders": null,
  "requestMethod": "",
  "requestUrl": "",
  "disableIPV6": false,
  "disableIPV4": false,
  "localAddress": null,
  "sessionId": null,
  "serverNameOverwrite": "",
  "streamOutputBlockSize": null,
  "streamOutputEOFSymbol": null,
  "streamOutputPath": null,
  "timeoutMilliseconds": 0,
  "timeoutSeconds": 0,
  "tlsClientIdentifier": "",
  "withDebug": false,
  "withCustomCookieJar": false,
  "withoutCookieJar": false,
  "withRandomTLSExtensionOrder": false
}
```

| Field               | Type                         | Description                                                                                                                              |
| ------------------- | ---------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| headers             | Map\<string, string>         | Headers to attach on the current request. defaultHeaders will be used when empty.                                                        |
| defaultHeaders      | Map\<string, Array\<string>> | Default Headers to be used when no request headers are specified. The default header order can be specified with the Key "Header-Order:" |
| connectHeaders      | Map\<string,Array\<string>>  | Headers to be used during the CONNECT request.                                                                                           |
| serverNameOverwrite | string                       | Lookup [Client Option ](/open-source-oasis/readme/client-options.md)"WithServerNameOverwrite"                                            |

* `sessionId` is optional. When not provided the API does not create a Session. On every forwarded request with a given sessionId you will receive the sessionId in the response to be able to reuse sessions (cookies).
* Be aware that `insecureSkipVerify` and the `timeoutSeconds` can not be changed during a session.
* `followRedirects` and `proxyUrl` can be changed within a session.
* If you do not want to set `requestBody` or `proxyUrl` use `null` instead of empty string
* When you set `isByteResponse` to `true` the response body will be a base64 encoded string. Useful when you want to download images for example.
* When you set `isByteRequest` to `true` the request body needs to be a base64 encoded string. Useful when you want to upload images for example.
* When you set `withProtocolRacing` to `true` the client will race HTTP/3 (QUIC) and HTTP/2 (TCP) connections in parallel, similar to Chrome's "Happy Eyeballs" approach. Cannot be used together with `forceHttp1` or `disableHttp3`. If you also set a `proxyUrl` it has to be a `socks5://` or `socks5h://` proxy that supports UDP ASSOCIATE, since only SOCKS5 can tunnel the UDP traffic HTTP/3 needs. Any other proxy scheme is rejected with an error.
* When you set `disableSessionTickets` to `true` the client does not cache TLS session tickets and never resumes a TLS session, so every connection performs a full handshake. Only profiles that support session resumption (those sending a PSK extension) are affected.
* When you set `withCustomCookieJar` to `true` a custom TLS-Client cookie jar will be used which is more suited for certain use cases. Otherwise the default Go cookie jar is used.

The `supportedSignatureAlgorithms` list of a custom TLS client additionally accepts `MLDSA44`, `MLDSA65`, `MLDSA87` and `GREASE`, which the Chrome 150 and Chrome 152 profiles use. `GREASE` is replaced with a value drawn from the connection's seed, so it changes per connection just like the built in profiles.

**trustAnchorsPayload**

Chrome 144 and later send the trust\_anchors extension (`51764`). A ja3 string lists extension IDs but carries no extension data, so if your `ja3String` contains `51764` you have to supply its payload separately in `trustAnchorsPayload`, as a hex string. Leaving it empty while the ja3 string asks for the extension fails the request with an error naming this field.

To get the value, open your fingerprint source in the browser you want to imitate, find the entry named `Unknown extension 51764` in the `tls.extensions` array and copy its `data` field whole. It already starts at the 16-bit list length.

```
{
  "ja3String": "771,...-51764,...",
  "trustAnchorsPayload": "00b80582df13020108839a648c9b2d010c08839a648c9b2d0107..."
}
```

Pass `"0000"` for an empty anchor list, which is what the Chrome 144 and Chrome 146 profiles send.

The anchor IDs are put in a fresh order once per client, because Chromium writes them in hash set iteration order, which stays the same for the life of a browser process and differs between processes. So the bytes on the wire are a reordering of what you supply, not a copy of it.

#### Custom TLS-Client

```
{
  "certCompressionAlgos": [],
  "connectionFlow": 0,
  "h2Settings": null,
  "h2SettingsOrder": null,
  "h3Settings": null,
  "h3SettingsOrder": null,
  "h3PseudoHeaderOrder": null,
  "h3PriorityParam": 0,
  "h3SendGreaseFrames": false,
  "headerPriority": null,
  "ja3String": "",
  "trustAnchorsPayload": "",
  "keyShareCurves": null,
  "priorityFrames": null,
  "alpnProtocols": null,
  "alpsProtocols": null,
  "ECHCandidatePayloads": null,
  "ECHCandidateCipherSuites": null,
  "pseudoHeaderOrder": null,
  "supportedDelegatedCredentialsAlgorithms": null,
  "supportedSignatureAlgorithms": null,
  "supportedVersions": null,
  "recordSizeLimit": 0,
  "streamId": 0,
  "allowHttp": false
}
```

<table><thead><tr><th width="277.3333333333333">Field</th><th width="258">Type</th><th>Description</th></tr></thead><tbody><tr><td>certCompressionAlgos</td><td>Array&#x3C;string></td><td>See possible values at the end of this page</td></tr><tr><td>connectionFlow</td><td>integer</td><td></td></tr><tr><td>h2Settings</td><td>Map&#x3C;string, int></td><td>See possible values for the Map keys at the end of this page.</td></tr><tr><td>h2SettingsOrder</td><td>Array&#x3C;string></td><td>Array of string keys which are used in the h2Settings property but ordered.</td></tr><tr><td>h3Settings</td><td>Map&#x3C;string, int></td><td>HTTP/3 settings. See possible values for the Map keys at the end of this page.</td></tr><tr><td>h3SettingsOrder</td><td>Array&#x3C;string></td><td>Array of string keys which are used in the h3Settings property but ordered.</td></tr><tr><td>h3PseudoHeaderOrder</td><td>Array&#x3C;string></td><td>Pseudo header order for HTTP/3 requests.</td></tr><tr><td>h3PriorityParam</td><td>integer</td><td>HTTP/3 priority parameter.</td></tr><tr><td>h3SendGreaseFrames</td><td>boolean</td><td>Whether to send GREASE frames in HTTP/3.</td></tr><tr><td>headerPriority</td><td>PriorityParam</td><td>See type definition below in next section</td></tr><tr><td>ja3String</td><td>string</td><td></td></tr><tr><td>trustAnchorsPayload</td><td>string</td><td>Hex payload for the trust_anchors extension (51764). Required if your ja3String lists that extension, since a ja3 string carries extension IDs but no extension data. See the note below.</td></tr><tr><td>keyShareCurves</td><td>Array&#x3C;string></td><td>See possible values at the end of this page</td></tr><tr><td>priorityFrames</td><td>Array&#x3C;PriorityFrames></td><td>See type definition below in next section</td></tr><tr><td>alpnProtocols</td><td>Array&#x3C;string></td><td>List of supported protocols for the ALPN Extension</td></tr><tr><td>alpsProtocols</td><td>Array&#x3C;string></td><td>List of supported protocols for the ALPS Extension</td></tr><tr><td>ECHCandidatePayloads</td><td>Array&#x3C;uint16></td><td>List of ECH Candidate Payloads</td></tr><tr><td>ECHCandidateCipherSuites</td><td>Array&#x3C;CandidateCipherSuite></td><td>See type definition below in next section</td></tr><tr><td>pseudoHeaderOrder</td><td>Array&#x3C;string></td><td>See possible values at the end of this page</td></tr><tr><td>supportedDelegatedCredentialsAlgorithms</td><td>Array&#x3C;string></td><td>See possible values at the end of this page</td></tr><tr><td>supportedSignatureAlgorithms</td><td>Array&#x3C;string></td><td>See possible values at the end of this page</td></tr><tr><td>supportedVersions</td><td>Array&#x3C;string></td><td>See possible values at the end of this page</td></tr><tr><td>recordSizeLimit</td><td>integer</td><td>TLS record size limit extension value</td></tr><tr><td>streamId</td><td>integer</td><td>Initial HTTP/2 stream ID</td></tr><tr><td>allowHttp</td><td>boolean</td><td>Allow plaintext HTTP connections</td></tr></tbody></table>

#### TransportOptions

```
{
  "disableKeepAlives": false,
  "disableCompression": false,
  "maxIdleConns": 0,
  "maxIdleConnsPerHost": 0,
  "maxConnsPerHost": 0,
  "maxResponseHeaderBytes": 0,
  "writeBufferSize": 0,
  "readBufferSize": 0,
  "idleConnTimeout": 0,
}
```

| Field                  | Type    | Description                                                                                                                   |
| ---------------------- | ------- | ----------------------------------------------------------------------------------------------------------------------------- |
| disableKeepAlives      | boolean |                                                                                                                               |
| disableCompression     | boolean | disables (automatic) decompression behavor as documented [here](/open-source-oasis/readme/response-body-encoding-decoding.md) |
| maxIdleConns           | integer |                                                                                                                               |
| maxIdleConnsPerHost    | integer |                                                                                                                               |
| maxConnsPerHost        | integer |                                                                                                                               |
| maxResponseHeaderBytes | integer | If zero, a default is used                                                                                                    |
| writeBufferSize        | integer | If zero, a default (currently 4KB) is used                                                                                    |
| readBufferSize         | integer | If zero, a default (currently 4KB) is used                                                                                    |
| idleConnTimeout        | integer | Duration in Nano Seconds                                                                                                      |

#### CandidateCipherSuite

<pre><code>{
<strong>    "kdfId": "",
</strong><strong>    "aeadId": "",
</strong><strong>}
</strong></code></pre>

| Field  | Type   | Description                                 |
| ------ | ------ | ------------------------------------------- |
| kdfId  | string | See possible values at the end of this page |
| aeadId | string | See possible values at the end of this page |

#### PriorityParam

<pre><code>{
<strong>    "streamDep": 0,
</strong><strong>    "exclusive": false,
</strong><strong>    "weight": 0
</strong><strong>}
</strong></code></pre>

| Field     | Type    | Description |
| --------- | ------- | ----------- |
| streamDep | integer |             |
| exclusive | boolean |             |
| weight    | integer |             |

#### PriorityFrames

```
{
    "streamID": 0,
    "priorityParam": null
}
```

| Field         | Type          | Description                   |
| ------------- | ------------- | ----------------------------- |
| streamId      | integer       |                               |
| priorityParam | PriorityParam | See type in the section above |
|               |               |                               |

#### Cookie Input

```
{
  "domain": "",
  "expires": 0,
  "maxAge": 0,
  "name": "",
  "path": "",
  "value": "",
  "secure": false,
  "httpOnly": false
}
```

<table><thead><tr><th>Field</th><th width="148">Type</th><th>Description</th></tr></thead><tbody><tr><td>domain</td><td>string</td><td></td></tr><tr><td>expires</td><td>integer</td><td>Unix Timestamp</td></tr><tr><td>maxAge</td><td>integer</td><td>Number of seconds the cookie is valid.</td></tr><tr><td>name</td><td>string</td><td></td></tr><tr><td>path</td><td>string</td><td></td></tr><tr><td>value</td><td>string</td><td></td></tr><tr><td>secure</td><td>boolean</td><td>Whether the cookie should only be sent over HTTPS.</td></tr><tr><td>httpOnly</td><td>boolean</td><td>Whether the cookie is inaccessible to client-side scripts.</td></tr></tbody></table>

If both `Expires` and `Max-Age` are set, `Max-Age` has precedence.

### Values

Here you can find the allowed possible string values to supply for fields like `supportedDelegatedCredentialsAlgorithms`, `supportedSignatureAlgorithms`, `supportedVersions` and much more.

#### H2Settings

```
"HEADER_TABLE_SIZE",
"ENABLE_PUSH",
"MAX_CONCURRENT_STREAMS",
"INITIAL_WINDOW_SIZE",
"MAX_FRAME_SIZE",
"MAX_HEADER_LIST_SIZE",
"UNKNOWN_SETTING_7",
"UNKNOWN_SETTING_8",
"UNKNOWN_SETTING_9",
```

#### H3Settings

```
"QPACK_MAX_TABLE_CAPACITY",
"MAX_FIELD_SECTION_SIZE",
"QPACK_BLOCKED_STREAMS",
"H3_DATAGRAM",
```

#### Supported Versions

```
"GREASE",
"1.3",
"1.2",
"1.1",
"1.0",
```

#### Supported Signature Algorithms

```
"PKCS1WithSHA256",
"PKCS1WithSHA384",
"PKCS1WithSHA512",
"PSSWithSHA256",
"PSSWithSHA384",
"PSSWithSHA512",
"ECDSAWithP256AndSHA256",
"ECDSAWithP384AndSHA384",
"ECDSAWithP521AndSHA512",
"PKCS1WithSHA1",
"ECDSAWithSHA1",
"Ed25519",
"SHA224_RSA",
"SHA224_ECDSA",
"MLDSA44",
"MLDSA65",
"MLDSA87",
"GREASE",
```

`MLDSA44`, `MLDSA65` and `MLDSA87` are the post quantum codepoints Chrome 150 and later advertise. `GREASE` is replaced with a value drawn from the connection's seed, so it differs per connection, the way Chrome 152 sends it. Both are only available for `supportedSignatureAlgorithms`, not for `supportedDelegatedCredentialsAlgorithms`.

#### certCompressionAlgorithm

```
"zlib",
"brotli",
"zstd",
```

#### Supported delegated credentials

```
"PKCS1WithSHA256",
"PKCS1WithSHA384",
"PKCS1WithSHA512",
"PSSWithSHA256",
"PSSWithSHA384",
"PSSWithSHA512",
"ECDSAWithP256AndSHA256",
"ECDSAWithP384AndSHA384",
"ECDSAWithP521AndSHA512",
"PKCS1WithSHA1",
"ECDSAWithSHA1",
"Ed25519",
"SHA224_RSA",
"SHA224_ECDSA"
```

#### KeyShareCurves

```
"GREASE",
"P256",
"P384",
"P521",
"X25519",
"P256Kyber768",
"X25519Kyber512D",
"X25519Kyber768",
"X25519Kyber768Old",
"X25519MLKEM768",
```

#### kdfIds

```
"HKDF_SHA256",
"HKDF_SHA384",
"HKDF_SHA512",
```

#### aeadIds

```
"AEAD_AES_128_GCM",
"AEAD_AES_256_GCM",
"AEAD_CHACHA20_POLY1305",
```
