Filtering Json Data

Hi!!

I am new with Make and i can´t the answer to this problem:

I am using google Document api to parse invoice document.

Using a http call i get a json ( here output sample: https://storage.googleapis.com/cloud-samples-data/documentai/SampleDocuments/INVOICE_PROCESSOR/pretrained-invoice-v2.0-2023-12-06_output.json)

The output json classify the data using “type” data. For example , type:“invoice_id” give you the invoice id. type:“line_item” is the data which correspond to one of the lines of the invoice document.

My question is, how can i get only the collection of data which correspond to type:“line_item” .

Using a iterator compont i want to add the data to my airtable file.

Thanks for your help.

Welcome to the Make community!

Iterate the entities array, and filter by type.

samliewrequest private consultation

Join the unofficial Make Discord server to chat with other makers!

2 Likes

Thank you!!! Solved. But now, i receive an erro 422 ( airtable ) “cannot accept the provided value”

I do like this:

{{parseNumber(get(map(31.properties; “mentionText”; “type”; “line_item/amount”); 1); “,”)}}

And my field type is number

Where is the problem

No problem, glad I could help!

1. If you have a new question in the future, please start a new thread. This makes it easier for others with the same problem to search for the answers to specific questions, and you are more likely to receive help since newer questions are monitored closely.

2. The Make Community guidelines encourages users to try to mark helpful replies as solutions to help keep the Community organized.

This marks the topic as solved, so that:

  • others can save time when catching up with the latest activity here, and
  • allows others to quickly jump to the solution if they come across the same problem

To do this, simply click the checkbox at the bottom of the post that answers your question:
Screenshot_2023-10-04_161049

3. Don’t forget to like and bookmark this topic so you can get back to it easily in future!

4. Do join the unofficial Make Discord server for live chat and video assistance

samliewrequest private consultation

Join the unofficial Make Discord server to chat with other makers!

2 Likes