Reading API call results

Good morning, everyone!

I’m about to tackle the most complex scenario we’ve encountered so far, and I could use your input.

  1. API Call for Data Extraction: I need to call an API to extract data from a database. Unfortunately, this API performs a data dump with no available filters, so I’ll receive an unstructured sequence of events. For context, the data will list all events chronologically, with the most recent items appearing at the bottom.

  2. Data Processing: I’ll need to read this data from the bottom up until I find a specific term from a set of possible terms (this could be the name of a specific meeting, which may vary). Once I locate the term, I’ll switch direction, reading back toward the end of the file to identify items marked by another set of terms (indicating meetings that included an election).

  3. Capturing Document IDs: For the items flagged with an “election” term, I need to capture their document IDs and store them in a Google Sheet.

  4. Expected Outcome: The goal is to generate a list of cleaned document IDs (stripping out any special characters or letters) that I can use later in a separate API call to download and store the corresponding PDF documents. But that’s a story for another day. :blush:

Any ideas, directions, or suggestions? I’m all ears!

Thanks, and have a fantastic week!

Welcome to the Make community!

I would suggest completing the Make Academy before jumping into building a complete scenario. If you need specific assistance when you are building a scenario it’s easier to help you then. Otherwise, you can also hire a professional by posting a request in the Hire a Pro category.

Here are some useful links and guides you can use to learn more on how to use the Make platform, apps, and app modules. I found these useful when I was learning Make, and hope they might benefit you too —

Getting Started

Help Centre Basics

Articles & Videos

If you need further assistance, please provide the following:

1. Relevant Screenshots

Please share screenshots of your scenario, any error messages, relevant module fields, and filters in question? It would really help other community members to see what you’re looking at.

You can upload images here using the Upload icon in the text editor:

2. Scenario Blueprint

Please export the scenario blueprint file to allow others to view the mapped variables in the module fields. At the bottom of the scenario editor, you can click on the three dots to find the Export Blueprint menu item.

3. Output Bundles of Modules

Please provide the output bundles of the modules by running the scenario (or get from the scenario History tab), then click the white speech bubble on the top-right of each module and select “Download input/output bundles”.

A. Upload as Text File

Save each bundle contents in your text editor as a bundle.txt file, and upload it here into this discussion thread.

B. Insert as Formatted Code Block

If you are unable to upload files on this forum, alternatively you can paste the formatted bundles.
These are the two ways to format text so that it won’t be modified by the forum:

  • Method 1: Type code block manually

    Add three backticks ``` before and after the content/bundle, like this:

    ```
    content goes here
    ```

  • Method 2. Highlight and click the format button in the editor

Providing the input/output bundles will allow others to replicate what is going on in the scenario even if they do not use the external service.

4. Link to API documentation, and example output bundle of your HTTP module when the API Is called

Following these steps will allow others to assist you here. Thanks!

1 Like