Skip to content

Latest commit

 

History

History
75 lines (53 loc) · 954 Bytes

File metadata and controls

75 lines (53 loc) · 954 Bytes
code type title
true
page
incrby | API | Core

incrby

Increments the number stored at key by the provided integer value. If the key does not exist, it is set to 0 before performing the operation.

[Redis documentation]


Query Syntax

HTTP

URL: http://kuzzle:7512/ms/_incrby/<_id>
Method: POST
Body:
{
  "value": <increment integer value>
}

Other protocols

{
  "controller": "ms",
  "action": "incrby",
  "_id": "<key>",
  "body": {
    "value": <increment integer value>
  }
}

Arguments

  • _id: key identifier

Body properties

  • value: the integer value to add to the key value

Response

Returns the incremented key value.

{
  "requestId": "<unique request identifier>",
  "status": 200,
  "error": null,
  "controller": "ms",
  "action": "incrby",
  "collection": null,
  "index": null,
  "result": 7
}