REST - BAQ with Parameters - Filter syntax?

I am working with v2 and trying to retrieve data from a BAQ that has built in parameters: @BeginDate, @EndDate, @OrderNum, however, I can’t figure out / find the syntax needed to set this data in the filter.

I’ve tried:
@OrderNum eq 363409
OrderNum eq 363409
$OrderNum eq 363409

What is the syntax to pass along a parameter in the filter?

Thank you.

It is BAQ - its field aliases are in the form of TableName_FieldName, you should use this syntax

No, I’m trying to pass a parameter value to the BAQ and there doesn’t appear to be the ability to to do this through the API GUI in my screenshot.

Instead, I just add the parameter to the URL string (e.g. /Data?EndDate=‘2022-01-18’&filter=…)

This article helped clear that up: Epicor Help

This is annoying. It’s been like this since 10.2.700 at least, maybe 600 also. I was hoping I was missing something but apparently not.

Specifically, it’s in the interactive help page where you run into this. It’s a shame, because I generally like this setup. I know you know @Adam, but I wanted to specify that in order to set up the following…

Workarounds that I know of:

  1. Test using v1 (boo)
  2. In the BAQ, give your parameters default values. The Swagger page will use those, while you are still free to override them in Postman or a browser
  3. Use Postman

Any chance this is better in Kinetic?

Also, I couldn’t open the link. It says I am forbidden to see the help file?!

What do you mean the Parameter shows up right here

It doesn’t for you? Mind you i’m in 2021.X

Hooray! They fixed it!

No, through 700 it’s not there:

1 Like

Looks like this is broke again in 2022.1.11 :frowning:

This BAQ has two parameters defined and none show up

Interestingly if you select v1 on the dropdown the Params show… weird…

That is interesting, I refactored to use the v2 api and is working good again

1 Like

Sorry for the necro but has anyone ever resolved this? I’m using the v2 api and cannot seem to find a way to use the baq parameters. Obviously I can filter using Odata but I’m pretty sure thats less efficient then parameter filtering.

You can filter parameters just fine in V2 it just doesn’t show up in swagger. But it works fine in postman.

Do you pass these as headers or is there a special syntax?

In the URL

1 Like

Thanks appreciate it.