we have to build a api based virtual service and url is as looks below .. it is get call.. (we also have post as well)
http://serverhost:8443/card_details/v1/debit-card/accounts/5556664/statuses
Here the input is account number i.e., 5556664.. every time new account number will be sent here from client to LISA..
I need to extract this account number and do several match rules/transactions in VSI..
can you please advise how can I extract this and make it as request argument in VSI .. what are the data protocols I need to use in model to achieve this.. ..
I do not believe the /web/CreditLimit?token=xxxxx will result in a 404 at the HTTP layer. The query string will be ignored in terms of HTTP's and the VSM's request matching against the base path of /web/CreditLimit. The base path is CaSe sensitive though so ensure you have allowed for that.
The query string should parse into arguments. The VSI can/will error if the number of parms in the VSI mismatch against the incoming request's query string. But, this error typically results in a "...Please expand the service..." message.
As a test,
- Set up your VSM to look watch with a base path of /web/CreditLimit.
- Deploy the VSM
- From a Browser, invoke the endpoint (http://<yourVseServer>:<listenPort>/web/CreditLimit?token=12345)
- Go into Inspection view for the service and you should see the operation display as GET /web/CreditLimit and the query string should parse into the Arg List as token = 12345. This is the same as the graphics that Kevin and Rick show in the 6th and 7th posts, above.
If this behavior does not occur, please report back so we can try to help further.