Discussions

 View Only

Cannot Insert into my table via Quickbase API

  • 1.  Cannot Insert into my table via Quickbase API

    Posted 09-27-2020 17:26
    I have successfully created my table, and access it via Curl in PHP.

    Now, am trying to insert and update my record via Curl. but each time I run my code it will display error. { "message": "Bad request", "description": "" }

    My token, user agent, content type will properly set in my code.

    Now assuming I want to insert into field username, email, name etc. This is how I send the request that triggers the error above.


    $post ='
    {
    "to": "mytable_id-goes-here",
    "data": [

    {
    "name": "jon Ball",
    "email: "jon@gmail.com",
    "username: "jonball",

    }

    ]
    }
    ';

    here is the documentation link am using. Thanks
    https://developer.quickbase.com/operation/upsert


    ------------------------------
    I have successfully created my table, and access it via Curl in PHP.

    Now, am trying to insert and update my record via Curl. but each time I run my code it will display error. { "message": "Bad request", "description": "" }

    My token, user agent, content type will properly set in my code.

    Now assuming I want to insert into field username, email, name etc. This is how I send the request that triggers the error above.


    $post ='
    {
    "to": "mytable_id-goes-here",
    "data": [

    {
    "name": "jon Ball",
    "email: "jon@gmail.com",
    "username: "jonball",

    }

    ]
    }
    ';

    here is the documentation link am using. Thanks
    https://developer.quickbase.com/operation/upsert



    ------------------------------