Dodaj wpis klucz-wartość użytkownika
POST
/api/v3/KeyValueStore/User/{userId}/{key}
const url = 'https://twoja-instancja-smerp-api.enterprise.sellrocket.pl/api/v3/KeyValueStore/User/1/example';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"additionalProperty":{}}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://twoja-instancja-smerp-api.enterprise.sellrocket.pl/api/v3/KeyValueStore/User/1/example \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "additionalProperty": {} }'Zapisuje nowy klucz z dowolną wartością JSON dla wskazanego użytkownika.
Metoda umożliwia dodanie nowej wartości klucza dla użytkownika. Wartość klucza może być dowolnym obiektem JSON.
Autoryzacja
Dział zatytułowany „Autoryzacja”Parametry
Dział zatytułowany „Parametry”Parametry ścieżki
Dział zatytułowany „Parametry ścieżki”userId
wymagane
integer format: int64
key
wymagane
string
Treść żądania
Dział zatytułowany „Treść żądania”Any JSON
Typ treściapplication/json
object
key
additional properties
object
options
object
propertyNameCaseInsensitive
boolean
parent
object
object recursive
root
object
object recursive
Examplegenerated
{ "additionalProperty": {}}Odpowiedzi
Dział zatytułowany „Odpowiedzi”If operation completed successfully
Typ treściapplication/json
object
id
integer format: int64
createdAt
string format: date-time
updatedAt
string format: date-time
version
integer format: int32
value
object
key
additional properties
object
options
object
propertyNameCaseInsensitive
boolean
parent
object
object recursive
root
object
object recursive
userId
integer format: int64
key
string
Examplegenerated
{ "id": 1, "createdAt": "2026-04-15T12:00:00Z", "updatedAt": "2026-04-15T12:00:00Z", "version": 1, "value": { "additionalProperty": {} }, "userId": 1, "key": "example"}
