Reputation: 41
I have created a flow in anypoint studio and using a raml file for invoking REST API. In this particular case I want to get the exact value of respective field specified in my RAML file.
E.g. In the message flow I want to get the exact value like emp_name.
Please help me to understand how can I can I achieve the same:
Below is my raml file
#%RAML 0.8
title: EmployeeInfo
version: 1.0
baseUri: http://server/api/{version}
/EmployeeDetails:
/{emp_name}:
get:
description: Get Employee information
responses:
200:
body:
application/json:
enter code here
Upvotes: 0
Views: 570
Reputation: 1
In the message flow these parameters turns into flow variables . You can directly use the flow variables to get the value you are looking .
Upvotes: 0
Reputation: 475
Better if you can post the logs with full error here, and also your mule config. I doubt that the error is on that logger since it could just log 'null' if not existing.
Upvotes: 0
Reputation: 11606
If you are using APIKIt generated flows in Mule, all URI params will be added as Flow Vars and all Query params will be inboundProperties. So "emp_name" will be available as a flowVar:
<logger level="INFO" message="#[flowVars.emp_name]" />
Upvotes: 4