PUT /accounts/{account_id}/storage/kv/namespaces/{namespace_id}/bulk
Write multiple keys and values at once. Body should be an array of up to 10,000 key-value pairs to be stored, along with optional expiration information. Existing values and expirations will be overwritten. If neither expiration
nor expiration_ttl
is specified, the key-value pair will never expire. If both are set, expiration_ttl
is used and expiration
is ignored. The entire request size must be 100 megabytes or less.
Servers
- https://api.cloudflare.com/client/v4
Path parameters
Name | Type | Required | Description |
---|---|---|---|
account_id |
String | Yes | |
namespace_id |
String | Yes |
Request headers
Name | Type | Required | Description |
---|---|---|---|
Content-Type |
String | Yes |
The media type of the request body.
Default value: "application/json" |
Request body fields
Name | Type | Required | Description |
---|---|---|---|
[] |
Array | Yes | |
[].expiration |
Number | No |
The time, measured in number of seconds since the UNIX epoch, at which the key should expire. |
[].base64 |
Boolean | No |
Whether or not the server should base64 decode the value before storing it. Useful for writing values that wouldn't otherwise be valid JSON strings, such as images. Default value: false |
[].key |
String | No |
A key's name. The name may be at most 512 bytes. All printable, non-whitespace characters are valid. |
[].metadata |
Object | No |
Arbitrary JSON that is associated with a key. |
[].value |
String | No |
A UTF-8 encoded string to be stored, up to 25 MiB in length. |
[].expiration_ttl |
Number | No |
The number of seconds for which the key should be visible before it expires. At least 60. |
How to start integrating
- Add HTTP Task to your workflow definition.
- Search for the API you want to integrate with and click on the name.
- This loads the API reference documentation and prepares the Http request settings.
- Click Test request to test run your request to the API and see the API's response.