# Is it possible to call Postman from Excel VBA?

**URL:** <https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954>\
**Category:** Help Hub\
**Created:** [August 6, 2022, 12:46pm UTC](https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954 "2022-08-06T12:46:44Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![marboe](https://avatars.discourse-cdn.com/v4/letter/m/c2a13f/32.png) [@marboe](https://community.postman.com/u/marboe)\
**Post date:** [August 6, 2022, 12:46pm UTC](https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954/1 "2022-08-06T12:46:44Z")

</div>

Hello,

I am wondering if Postman can be a solution for my problem.

I am looking for a solution to call and extract data from an api-server and generate a dataframe (in a user friendly way) once a minute. Next I would like run a script in Excel VBA which imports the data once a minute from Postman. Would this be possible?

(Alternatively I could call the api-server directly from Excel VBA, although it is very tough to process the received data into the correct data frame in Excel VBA.)

Thanks a lot!

---

<div class="post-metadata">

**Author:** ![w4dd325](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/w4dd325/32/12436_2.png) [@w4dd325](https://community.postman.com/u/w4dd325)\
**Post date:** [August 6, 2022, 4:16pm UTC](https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954/2 "2022-08-06T16:16:35Z")

</div>

Hi @marboe

You could probably achieve this using a webhook;

[![](https://img.youtube.com/vi/wdLvXKkXhLk/maxresdefault.jpg "Postman Webhooks | Postman Level Up") ](https://www.youtube.com/watch?v=wdLvXKkXhLk)

---

<div class="post-metadata">

**Author:** ![marboe](https://avatars.discourse-cdn.com/v4/letter/m/c2a13f/32.png) [@marboe](https://community.postman.com/u/marboe)\
**Post date:** [August 7, 2022, 1:12pm UTC](https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954/3 "2022-08-07T13:12:04Z")

</div>

Hi w4dd325,

I have watched and read about webhooks. Is this not about reporting performance metrics of an api instead of transmitting data?

> **[Custom webhooks | Postman Learning Center](https://learning.postman.com/docs/integrations/webhooks/)**
>
> Custom webhooks: documentation for Postman, the collaboration platform for API development. Create better APIs—faster.

I am looking to do this steps if possible:

1. call an api from Postman
2. process the data from this api within Postman
3. generate a table from this data in Postman
4. read the table into Excel vba by calling Postman from Excel

Thanks!

---

<div class="post-metadata">

**Author:** ![w4dd325](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/w4dd325/32/12436_2.png) [@w4dd325](https://community.postman.com/u/w4dd325)\
**Post date:** [August 8, 2022, 9:20am UTC](https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954/4 "2022-08-08T09:20:37Z")

</div>

A webhook would let you trigger an event inside Postman.

You would set up a webhook that does action and after setting it up you would have a URL you can use, in Excel you can then call that URL, which then triggers the event in Postman.

“Generating a table” might be a challenge as Postman is mainly used for sending requests and receiving a response.

---

<div class="post-metadata">

**Author:** ![marboe](https://avatars.discourse-cdn.com/v4/letter/m/c2a13f/32.png) [@marboe](https://community.postman.com/u/marboe)\
**Post date:** [August 9, 2022, 8:49am UTC](https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954/5 "2022-08-09T08:49:11Z")

</div>

Thanks @ w4dd325 . The solution I am looking for is to simplify the generation of the table (dataframe) from the data extracted from the api. This because this is quite tough from an Excel VBA array (which is the input received if I call the api directly in Excel VBA).

If generating a table in Postman is a challenge, I should probably look for an alternative solution. Maybe I should set up the api call with the contruction of the table in R or Python. Thanks a lot for your thoughts and time!

---

<div class="post-metadata">

**Author:** ![w4dd325](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/w4dd325/32/12436_2.png) [@w4dd325](https://community.postman.com/u/w4dd325)\
**Post date:** [August 9, 2022, 9:58am UTC](https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954/6 "2022-08-09T09:58:18Z")

</div>

You could visualise the data in HTML within Postman but I don’t know if you could extract it as a table … maybe you can.

Here is an example;

```auto
var template = `
    <style type="text/css">
        .tftable {font-size:14px;color:#333333;width:100%;border-width: 1px;border-color: #87ceeb;border-collapse: collapse;}
        .tftable th {font-size:18px;background-color:#87ceeb;border-width: 1px;padding: 8px;border-style: solid;border-color: #87ceeb;text-align:left;}
        .tftable tr {background-color:#ffffff;}
        .tftable td {font-size:14px;border-width: 1px;padding: 8px;border-style: solid;border-color: #87ceeb;}
        .tftable tr:hover {background-color:#e0ffff;}
    </style>
    
    <table class="tftable" border="1">
        <tr>
            <th>Name</th>
            <th>Email</th>
        </tr>
        
        {{#each response.data.contacts}}
            <tr id=row_{{@key}} onClick="handleClick(this.id)">
                <td id={{@key}}>{{name}}</td>
                <td>{{email}}</td>
            </tr>
        {{/each}}
    </table>
`;

pm.visualizer.set(template, {
    response: pm.response.json()
});

```

* * *

Output;

 ![image](https://us1.discourse-cdn.com/getpostman/original/3X/1/b/1bb8d06a1db22cf43d4a5dbb67239aa151078f66.png)

---

<div class="post-metadata">

**Author:** ![marboe](https://avatars.discourse-cdn.com/v4/letter/m/c2a13f/32.png) [@marboe](https://community.postman.com/u/marboe)\
**Post date:** [August 9, 2022, 10:18am UTC](https://community.postman.com/t/is-it-possible-to-call-postman-from-excel-vba/37954/7 "2022-08-09T10:18:18Z")

</div>

I expect the extra complexity from the HTML transformation will not make the whole route from api to Excel easier for me. Thanks!
