Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

POST API Variables

superjesse
8 - Asteroid

Hello folks. I'm trying to POST to Service Now via an API using the download tool. My biggest challenge is passing the variables along with it. I have 8 variables I need to send. I was reading another solution about creating a JSON file with JSON Build.  I just can't figure out how to create a separate JSON for each record that comes through.

 

Example data below.

 

superjesse_0-1680298026303.png

 

 

 

3 REPLIES 3
apathetichell
19 - Altair

you need to use a transpose to get these into a format where the json can be in a key/value pair. Basically whatever you are sending in your api call should be found in your body variable in your first record (or each body in each record). This usually means you need to use a summarize tool to concatenate your payload to create your body.

superjesse
8 - Asteroid

Thank you for the quick response. I do understand the transpose and key/pair.  But how do I separate them by each instance?  If I transpose, doesn’t it go down the whole column? How does it know when the next record starts?  

ArtApa
Alteryx
Alteryx

Hi @superjesse - You need to add Record ID before transpose. Then select RecordID field as a Key Column in Transpose. Finally, You will group by RecordID in JSON Build:

ArtApa_1-1680324293171.png

 

 

ArtApa_0-1680324272697.png

 

Labels
Top Solution Authors