Access Control Example
The Implementing Access Control page has been updated with links to the relevant areas on how to implement access control.
As part of the effort to help ATSs implement Access Control, the following have been added:
hapiApi additions
jwtHeaderValuePrefixwhich is used when attaching thex-authorizationheader to the request headers. The default isBearer TOKENHEREand the setter functionsetJWTHeaderValuePrefixresponseInterceptorIdandresponseInterceptorOptionsto be able to add response interceptor so that any response with status401can run side effectsretryOptionsfor theaxios-retrypackage so it can be changedonAfterResponseFulfilledHandlerandonAfterResponseRejectedHandlercallback functions to run side effects on response statusremoveResponseInterceptorFromAxiosInstanceandaddResponseInterceptorToAxiosInstanceto eject and inject the response interceptor based on values ofonAfterResponseFulfilledHandlerandonAfterResponseRejectedHandlergetModuleConfigs,getFlattenedModuleConfigs,getFlattenedModuleConfigURLs,getFlattenedModuleConfigURLPathsfunctions to help ATSs figure out routes of HAPI Backend for their Access Control implementations