REST API Post Body?

I am a brand new user of appgyver and trying to get a REST API post that sends JSON in the body. I have it working in Postman just fine but cant seem to understand how/where to put this in Appgyver. I have 2 headers Token and Content/Type and their values entered but dont see where/how to enter what postman calls “body” as json. How can I do this?

Also just a suggestion: Nearly every programmer uses Postman why all the various Nocode solutions have to use different terminology and UI is beyond me. For faster onboarding, I would suggest the following.

  1. Allow copy/paste of cURL as many example API docs use this and it works in Postman
  2. Allow for import of a Postman Collection
  3. Copy the Postman UI and terminology to the pixel. see below:
1 Like

Instead of a freeform JSON body, a REST API integration works so that you define the schema of the body payload in the Schema tab in Composer. When you do this, the Create record flow function (which triggers a POST request) will initialize correctly, ensuring your inputs conform to what the backend expects.

So, your POST request schema would have an inputs key object with properties and so on; here I’ve started configuring the schema based on your screenshot.

Imports from various sources (including Swagger) are a good idea, added it to our issue tracker as a feature request: https://tracker.appgyver.com/feature-requests/p/initialize-rest-api-config-by-importing-a-curlswaggerpostman-collectionetc

Updates to the UI are also in the pipeline, and definitely would make sense to at least explain that “Request schema defines what will be sent in the POST request body”.

We really need to fix the error reporting there to be more informative – can you check the web inspector console via Ctrl+Shift+I (or Cmd+Opt+I on Mac) and see if there’s a more informative error there? Sorry for the hurdles.

Estou passando por um problema parecido e imagino que poderia ser resolvido se a chave input no exemplo fosse vazio.
Por exemplo: um objeto de três propriedade, porém sem cabeça
{
“id”: “564649”,
“name”: “Portela”,
“city”: “Maceió”
}

Hi,

I’m also need to send a json body to my endpoint (graphql). Could you @Harri_Sarsa provide a bit more detail on how to add json to the body. Mine would need to look like this:

{
“query”:“query {candidates{name years_exp li_url job_title notes id educations{school_name}}}”
}

Could you also point me in the right direction to find out how to add variables to the json body as well?

Many thanks,

Michael

Hi!

When using Create record the “record properties” object will be sent as the JSON payload for the request.

I suggest for example binding “record properties” to a page variable (that is of object type), you can then dynamically change the data to be sent with the POST request.