Skip to main content
Question

about update API

  • Jan 12, 2023 12:36 AM UTC
  • 11 replies
  • 324 views

We need nearly 1000 fields to use,I want to add a new fields with Update API or Create API.Is it possible with the API?

 

11 replies

Liz
Ex–Typefomer
Forum|alt.badge.img+5
  • Tech Community Advocate
  • Jan 12, 2023 3:52 PM UTC

Hi @takashi ohtsuka You can definitely use the Create API to update your form. The documentation for this can be found here. 😀


Hi @Liz 

Thanks for your reply.

 

I used Create API [/forms] with simple form.

Response is this.

error
{
code: 'VALIDATION_ERROR',
description: 'The payload is invalid.',
details: [
{
code: 'NOT_ALLOWED_PROPERTY',
description: 'should NOT have additional properties',
field: '/fields/0/id',
in: 'body'
},
{
code: 'NOT_ALLOWED_PROPERTY',
description: 'should NOT have additional properties',
field: '/fields/1/id',
in: 'body'
},
{
code: 'NOT_ALLOWED_PROPERTY',
description: 'should NOT have additional properties',
field: '/fields/1/choice/0/id',
in: 'body'
},
{
code: 'NOT_ALLOWED_PROPERTY',
description: 'should NOT have additional properties',
field: '/thankyou_screens/0/id',
in: 'body'
},
{
code: 'NOT_ALLOWED_PROPERTY',
description: 'should NOT have additional properties',
field: '/thankyou_screens/1/id',
in: 'body'
}
]
}
400

 

So, I tested API /forms with EXAMPLE JSON.

 

I got a similar error.


Liz
Ex–Typefomer
Forum|alt.badge.img+5
  • Tech Community Advocate
  • Jan 13, 2023 5:21 PM UTC

Hi @takashi ohtsuka Do you happen to have a link of the request you made? Hopefully it’s just a simple error, but that’ll help me understand where these errors are coming from. 


Grace
Community Team
Forum|alt.badge.img+5
  • Community Advocate
  • Jan 23, 2023 9:50 AM UTC

Hey @takashi ohtsuka don’t forget to share the link so we can look into these errors 🙏


So, I tested API /forms with EXAMPLE JSON.


i think type form is really fxxxkin 


Liz
Ex–Typefomer
Forum|alt.badge.img+5
  • Tech Community Advocate
  • Jan 24, 2023 5:14 PM UTC

Hi @takashi ohtsuka happy Tuesday! I’m not quite sure I understand. Did the test call work for you? 😀


  • Navigating the Land
  • Mar 10, 2023 1:34 PM UTC

I’ve got the same error when I send JSON payload from TypeForm example page (https://www.typeform.com/developers/create/reference/create-form/)

 

 

 
 

After I removed problem fields from my requests it works.

So it seems the example in documentation is invalid?

 


Forum|alt.badge.img+5
  • Community Wizard
  • Mar 10, 2023 3:57 PM UTC

You should share the JSON payload you sent. Otherwise, it is impossible to tell what is wrong.


  • Navigating the Land
  • Mar 10, 2023 7:07 PM UTC

You should share the JSON payload you sent. Otherwise, it is impossible to tell what is wrong.

As I said, I’ve send JSON from the API developers page: https://www.typeform.com/developers/create/reference/create-form/

The whole example of JSON payload.
 

 


Forum|alt.badge.img+5
  • Community Wizard
  • Mar 22, 2023 1:40 PM UTC

Just tried the example JSON from example. It worked fine. I had to remove the GTM property as it is not compatible with the payment field. But this is an example from the doc meant to show all properties, which you can just tweak.

An other option that works great for me is to start the form in the GUI, then read it with the API and modify it to add the fields I need programmatically.