# KV Store


# Functions

top-level functions:                                                                                                                                                       

prefect.backend.kv_store.set_key_value

(key, value)[source]

Set key value pair, overwriting values for existing key

Args:

  • key (str): the name of the key
  • value (Any): A json compatible value
Returns:
  • id (str): the id of the key value pair
Raises:
  • ClientError: if using Prefect Server instead of Cloud
  • ValueError: if value exceeds 10 KB limit

prefect.backend.kv_store.get_key_value

(key)[source]

Get the value for a key

Args:

  • key (str): the name of the key
Returns:
  • value (Any): A json compatible value
Raises:
  • ValueError: if the specified key does not exist
  • ClientError: if using Prefect Server instead of Cloud

prefect.backend.kv_store.delete_key

(key)[source]

Delete a key value pair

Args:

  • key (str): the name of the key
Returns:
  • success (bool): Whether or not deleting the key succeeded
Raises:
  • ValueError: if the specified key does not exist
  • ClientError: if using Prefect Server instead of Cloud

prefect.backend.kv_store.list_keys

()[source]

List all keys

Returns:

  • keys (list): A list of keys
Raises:
  • ClientError: if using Prefect Server instead of Cloud

This documentation was auto-generated from commit n/a
on February 23, 2022 at 19:26 UTC