0

So I created a endpoint inside the raml file such as:

    /proxy:
  /{proxyDestinationTarget}:
    uriParameters:
      proxyDestinationTarget: 
        type: string
        example: "myurl.com"
    post:
      description: Pass through operation that targets IAA 
      is: [client-credentials-required,standard-error-responses,traceHeaders]

and then inside of the logic.xml in my variable component I have

attributes.uriParams.'proxyDestinationTarget'

when I send the request in postman and debug i am getting a uriParams size of 0 the url i entered in postman is

https://localhost:8092/proxy/uat.something.somethingElse.com/Assign/Assignment.svc

but if i send a request like this :

https://localhost:8092/proxy/uat.something.somethingElse.com

I get a uriParam size = 1 which is what I want. I guess the / is whats causing the problem. how can I pass url as uri param with escape characters???

aled
  • 21,330
  • 3
  • 27
  • 34
aquile hollins
  • 161
  • 1
  • 8
  • RAML and OAS is designed to let you document all the resources. So wildcards in URI or proxy endpoints are not supported in any AFAIK. If you really need it you can use http listener directly and enter the `path` with wildcards. – Harshank Bansal May 24 '22 at 19:53

1 Answers1

0

It looks like you are not sending an URL that matches the RAML definition in the first case.

For the URL:

https://localhost:8092/proxy/uat.something.somethingElse.com/Assign/Assignment.svc

The RAML defined that the API should expect /proxy/{proxyDestinationTarget} but it is receiving something like /proxy/{proxyDestinationTarget}/Assign/Assignment.svc, where {proxyDestinationTarget} is uat.something.somethingElse.com, but nothing matches /Assign/Assignment.svc. The API should include those two last components too to match. It is not escaping them, they probably need to be defined.

aled
  • 21,330
  • 3
  • 27
  • 34