New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Assign environment variables in published documentation through query parameters #308

Closed
aarunraja opened this Issue Aug 29, 2018 · 2 comments

Comments

Projects
None yet
4 participants
@aarunraja
Copy link

aarunraja commented Aug 29, 2018

Hi,
In the Main page, I have loaded published code in an iframe. The main page has authentication machinimas. How I can pass auth token from main page to the {$$.env.oauth_access_token} variables in the stoplight published code in Iframe. So the my API call will get success.

image

@tbarn tbarn added the Next label Aug 30, 2018

@rossmcdonald

This comment has been minimized.

Copy link

rossmcdonald commented Sep 11, 2018

Hi @aarunraja, apologies for the delay! This feature is not released yet, but it will work by passing in the variables through query parameters being passed to your iframe. So in your example above, you would want to pass in an oauth_access_token query parameter (ie, ?oauth_access_token=abc123) through to the iframe rendering the document.

We will update this issue once the functionality is available.

@rossmcdonald rossmcdonald changed the title How to assign Environment variable form Main page. Assign environment variables in published documentation through query parameters Sep 11, 2018

@lottamus

This comment has been minimized.

Copy link
Member

lottamus commented Sep 19, 2018

Hey @aarunraja,

This feature has been added and deployed. You will need to republish your Hub for it to work.

@lottamus lottamus closed this Sep 19, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment