Anyone willing to help a newbie out with postman?

So I’m trying to learn more about REST. I am able to get some list and make some new rows within the swagger help. I see lots of things saying that Postman is a good application to use to start developing things. So I have it downloaded and am able to go the basic get list and post some new rows from the information that I was able to get from swagger. So far so good.

I remembered seeing, and they talk about sample collections in the help docs for postman so I looked up Brian Conner’s postman example collection and I’m trying to get those imported to postman. But this is where I get stuck.

The help link for how to import a collection basically just restates the title of the tabs, but being new to all this, those titles don’t really mean anything to me. Can someone give me a quick rundown of what I do with the big block of code from GitHub and how I get them to show in the collection tree?

Thanks in advance.
Brandon

Do you mean the json text that shows when you click the collection link? You can either save it to a file or just copy the text and use the IMPORT feature on POSTMAN. There is an option to import raw text

Once imported, use the collections tab to view (dont forget to set up your environment though)

And finally- dont forget to set the credentials

image

2 Likes

That’s why I got messed up. The link listed goes to the create new instead of import, so the instructions don’t make sense for importing. Now that I used that button. It works great. I am able to get it working now.

Now I just have to explore some of the tools.

2 Likes

Have you tried using jquery?

never heard of it…

So I’m trying some of the queries, and I’m trying the BAW lins tiwth company in query string, and the one with the header. Below is one of the examples.

{{Host}}/api/v1/BaqSvc/?Company=YOURCOMPANY

For some reason the “pretty” part shows this,

image

But the raw looks like it brought back the list.

Is this just a setting in Postman that’s messed up? Or is that just something that doesn’t work all of the time? Or am I doing something wrong? Does it even matter :confused:

Note: other things work fine. It just seems to be the list of BAQ’s doing this.

Are you putting YOURCOMPANY in single quotes?

nope. It does the same thing with single quotes and no quotes. Double quotes don’t work at all.

I was messing with the language settings (buttonitis here) and changed the language detection to JSON becuse rest is all JSON right??? I changed that back and now it returns the XML in the “pretty” version.

image

Looking back at your URL, I don’t see the name of the BAQ in there before the COMPANYNAME. This is what my BAQSSvc call looks like:

/api/v1/BaqSvc/TrialBalance?Company=‘EPIC01’&FiscalYear=2014&BeginPeriod=1&EndPeriod=1

TrialBalance is the name fo the BAQ.

Mark W.

The example is actually getting a list of all of the BAQ’s filtered by company. Not especially helpful, I’m just exploring. For some reason, that call sends back XML instead of JSON.

FWIW, I get an error on that command too. Might be a bug or a mistake in the documentation.

Mark W.

it works for me, as long as I am expecting XML instead of JSON.

Might be worth sending in a ticket…

:tickets:

but that ones not golden!
image

You need to specify which BAQ you want to get. Only the BAQ information gets sent in JSON, if you do not specify any, a list of BAQs in XML code will be display… Try it out. you don´t even need post man for that, just put something like this in a web browser

https://yourserver/api/v1/BaqSvc/BAQID

it will ask for your EPICOR credentials

1 Like

Another question,

Do you always have to use raw for the body? There is a section to use form data, but doesn’t look like it formats the code correctly.

image

Must be raw, but you can change TEXT to JSON for prettier formatting
image

1 Like