okta-cli icon indicating copy to clipboard operation
okta-cli copied to clipboard

Add ability to handle non-JSON endpoints

Open aogail opened this issue 1 year ago • 2 comments

Add an option to pass arbitrary HTTP request headers in the raw command, for endpoints such as [app]/sso/saml/metadata that are not JSON. Also do not attempt to parse the body as JSON if the content type indicates something other than JSON.

Example usage:

$ okta-cli raw -H 'Accept: application/xml' 'apps/id/sso/saml/metadata'
<?xml version="1.0" encoding="UTF-8"?><md:EntityDescriptor entityID="http://www.okta.com/...

aogail avatar Jan 05 '24 17:01 aogail

oh! love the MR, I kinda missed this. will try to resolve the conflicts soon :)

flypenguin avatar Feb 07 '24 16:02 flypenguin

Hi @flypenguin, I rebased onto the current main to resolve the conflicts.

aogail avatar May 20 '24 21:05 aogail