Note
All URIs are relative to https://api.fastly.com
Method | HTTP request | Description |
---|---|---|
delete_key_from_store | DELETE /resources/stores/kv/{store_id}/keys/{key_name} | Delete kv store item. |
get_keys | GET /resources/stores/kv/{store_id}/keys | List kv store keys. |
get_value_for_key | GET /resources/stores/kv/{store_id}/keys/{key_name} | Get the value of an kv store item |
set_value_for_key | PUT /resources/stores/kv/{store_id}/keys/{key_name} | Insert an item into an kv store |
Delete an item from an kv store
let cfg = &Configuration::default();
let params = DeleteKeyFromStoreParams {
// parameters
};
delete_key_from_store(cfg, params)
Name | Type | Description | Required | Notes |
---|---|---|---|---|
store_id | String | [required] | ||
key_name | String | [required] |
(empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to README]
List the keys of all items within an kv store.
let cfg = &Configuration::default();
let params = GetKeysParams {
// parameters
};
get_keys(cfg, params)
Name | Type | Description | Required | Notes |
---|---|---|---|---|
store_id | String | [required] | ||
cursor | Option<String> | |||
limit | Option<i32> | [default to 100] | ||
prefix | Option<String> |
crate::models::InlineResponse2004
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to README]
Get the value associated with a key.
let cfg = &Configuration::default();
let params = GetValueForKeyParams {
// parameters
};
get_value_for_key(cfg, params)
Name | Type | Description | Required | Notes |
---|---|---|---|---|
store_id | String | [required] | ||
key_name | String | [required] |
String
- Content-Type: Not defined
- Accept: application/octet-stream
[Back to top] [Back to API list] [Back to README]
Set a new value for a new or existing key in an kv store.
let cfg = &Configuration::default();
let params = SetValueForKeyParams {
// parameters
};
set_value_for_key(cfg, params)
Name | Type | Description | Required | Notes |
---|---|---|---|---|
store_id | String | [required] | ||
key_name | String | [required] | ||
if_generation_match | Option<i32> | |||
time_to_live_sec | Option<i32> | |||
metadata | Option<String> | |||
add | Option<bool> | |||
append | Option<bool> | |||
prepend | Option<bool> | |||
background_fetch | Option<bool> | |||
body | Option<String> |
String
- Content-Type: application/octet-stream
- Accept: application/octet-stream