configure query parameter in target end point

sjm2000-1
Participant I

Dear All,

i have a target url which looks like below.

https://domain.com/arsys/services/ARService?server=nnn&webService=ab:1345:90

I am unable to configure in the target endpoint (OPDK latest version). Its saying invalid xml.

Any ideas?

Thanks

Solved Solved
0 4 1,458
1 ACCEPTED SOLUTION

you can use cdata sections to allow the ampersand in the XML.

Or, you can escape it to & amp ;

On the other hand, I wouldn't do that. I wouldn't embed those query params in the TargetEndpoint.

Instead I would use an AssignMessage policy attached to the Target request flow to inject those query params.

<AssignMessage name='AM-1'>
  <Set>
    <QueryParams>
      <QueryParam name='server'>nnn</QueryParam>
      <QueryParam name='webService'>ab:1345:90</QueryParam>
    </QueryParams>
  </Set>
</AssignMessage>

View solution in original post

4 REPLIES 4

sjm2000-1
Participant I

I mean to say the & is creating problem in apigee proxy xml .

you can use cdata sections to allow the ampersand in the XML.

Or, you can escape it to & amp ;

On the other hand, I wouldn't do that. I wouldn't embed those query params in the TargetEndpoint.

Instead I would use an AssignMessage policy attached to the Target request flow to inject those query params.

<AssignMessage name='AM-1'>
  <Set>
    <QueryParams>
      <QueryParam name='server'>nnn</QueryParam>
      <QueryParam name='webService'>ab:1345:90</QueryParam>
    </QueryParams>
  </Set>
</AssignMessage>

Looks like a great idea 🙂 .Let me try it out in few hours . Will get back with result soon.

yes it works. Thank you