Solved

Creating a card with an option field via api

  • 5 July 2022
  • 2 replies
  • 90 views

Userlevel 1

Hey,

 

So I can create a card which works fine via Javascript, the issue I’m facing is populating the radio field.

 

Here’s my code:

const query = `mutation {
createCard(input: {
pipe_id:302543188,
title: "New card 2",
fields_attributes:[
{field_id: "options", value: "Yes"},
],
}) {
card {
title
}
}
}`

 

The field in question has a name “Options” with a yes and no option.

 

Any help would be great.

icon

Best answer by João Nicolete 6 July 2022, 20:26

View original

2 replies

Userlevel 2

Hi!

 

The problem is thats the correct param is “field_value”, not only “value”. If you correct it, it should work fine. You can see a example here: https://developers.pipefy.com/reference/cards

 

Let me know if that worked!

Userlevel 1

Thanks, can’t believe I missed that 🤦🏻

Reply