Backbench Docs
  • Introduction
  • Getting Started
    • BBLANG
    • Node
    • Python
    • Go
  • Backbench Features and UI workflow
  • API Reference
    • BBLANG
    • Node
    • Python
    • Go
  • 3rd Party Integrations
    • Login using Facebook
    • Login using Google
    • Login with Twitter
    • Login using LinkedIn
    • Connection with MongoDB
    • Connection with MySQL
    • Geo Location Integration
    • Integration with AWS S3
    • Integration with Google Cloud Storage
    • Integration with Razorpay
    • Integration with Stripe
    • Integration with Mailchimp
    • Integration with Segment
    • Sending Emails with SendGrid
    • Sending Emails with Mailgun
    • Sending SMS with Twilio
    • Sending Push Notification with Pushwoosh
  • Troubleshooting and support
    • CNAME Support
    • FAQS
    • Error Codes
  • Testing
Powered by GitBook
On this page
  • REST API
  • Memory
  • Logs

API Reference

Use the pre-programmed API Reference material by Backbench when developing your applications.

REST API

Memory

Send aPOSTrequest to endpoint https://memory.backbench.io.

The request body/payload has the following format:

{
    "cmd": "",
    "auth": {
        "benchId": "",
        "userId": "",
        "accessKey": ""
    },
    "args": {
    },
    "json": true
}

cmd, args: are operation depedent. auth: Used as security for API, It has 3 mandatory properties - benchId, userId, accessKey. accessKey value can be accessed from environment variable ACCESS_KEY.

Setting Memory

"cmd" : "bb:mem:set" 
"args": {"key": "", "value": ""}

Getting Memory

"cmd" : "bb:mem:get"
"args": {"key": ""}

Deleting Memory

"cmd" : "bb:mem:del"
"args": {"key": ""}

An example payload for setting up memory in backbench.

{
    "cmd": "bb:mem:set",
        "auth": {
            "benchId": "aaaaa0",
            "userId": "mybench",
            "accessKey": "c72d2f3a91b80c1e7fb46f4332383795facd8e99df31b689513c2fa11a699adb"
        },
        "args": {
            "key": "jlo",
            "value": "one the floor"
        }
}

Logs

Payload for logs goes like this;

"cmd" : "bb:log"
"args": {"message": ""}
PreviousBackbench Features and UI workflowNextBBLANG

Last updated 6 years ago