Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

OAS Validation Policy with Object in HTTP-Header

Hello,

I'm using apigee OAS Validation policy to validate incoming request against an open-api (swagger) file.

I have an http header definition which points to object that contains two fields:

    DateRange:

      type: object

      properties:

        fromDate:

          $ref: '#/components/schemas/IsoDate'

        toDate:

          $ref: '#/components/schemas/IsoDate'

 

this is the header value sent in the request:

ReturnedDate: {"fromDate": "20211215", "toDate": "20211215"}

but for some reason, since there is a comma in the value, I'm getting validation error saying "Multiple values found for parameter but it is not an array"

It's work fine with this value:

ReturnedDate: {"fromDate": "20211215"}

 

any ideas?

 

Thanks,

Kobi.

 

0 0 189
0 REPLIES 0