I should use few constraints for our APIs per user. for example (after validation of token) checking IP address, checking specific parameter in query string and other custom constraints which maybe required to fetch data from data base . what is the suitable solution to implement this constraint in API call time? using custom mediator in outflow? using scope feature? using throttling policy or other. thank you for your answer!
1 Answers
1
votes
I think the best approach is to write a custom handler which allows you to customise as your requirement. This will help you to check all your extra constraints easily. Please refer this document for more details.
And also you may be able to achieve this using a custom mediation flow too. But that depends on how granular you need to check the constraint. If checking does not involve a complex logic, then simple mediation flow would help you. Please refer this document for more details.