Watson: verschil tussen versies
(Nieuwe pagina aangemaakt met '{{sys:back|page=Webdesign}} {{#tag:easytree| Watson :{{#tag:easyview|https://leafletjs.com/examples/quick-start/|type=iframe|thumbnail=Quickstart}} :To authenticate...') |
Geen bewerkingssamenvatting |
||
(10 tussenliggende versies door dezelfde gebruiker niet weergegeven) | |||
Regel 2: | Regel 2: | ||
{{#tag:easytree| | {{#tag:easytree| | ||
Watson | Watson | ||
: | :Authenticate:<ref name="aut">informatie afkomstig van [https://cloud.ibm.com/docs/account?topic=account-iamapikeysforservices IBM]</ref> | ||
:To authenticate with a service's API by using an access token, complete the following steps: | ::To authenticate with a service's API by using an access token, complete the following steps | ||
::1 - First, [https://cloud.ibm.com/docs/account?topic=account-userapikey#manage-user-keys create an IBM Cloud API key] if you have not already. | |||
:2 - The next step for the API client is the retrieval of an IAM access token, as described in Getting an IAM token from an API key. | ::2 - The next step for the API client is the retrieval of an IAM access token, as described in [https://cloud.ibm.com/docs/account?topic=account-iamtoken_from_apikey Getting an IAM token from an API key]. | ||
:3 - From the response, extract the property access_token to get the IAM access token. expires_in indicates the seconds until the IAM access token access_token expires. Either use this relative value or the absolute time stamp expiration based in UNIX time. | ::3 - From the response, extract the property <tt>access_token</tt> to get the IAM access token. expires_in indicates the seconds until the IAM access token <tt>access_token</tt> expires. Either use this relative value or the absolute time stamp expiration based in UNIX time. | ||
:4 - Send the IAM access token as described in RFC 6750, section 2.1. Authorization Request Header Field: | ::4 - Send the IAM access token as described in [https://tools.ietf.org/html/rfc6750#page-5 RFC 6750, section 2.1. Authorization Request Header Field]: | ||
:Review the following example: | ::Review the following example: | ||
:1 - Use the HTTP header Authorization | ::1 - Use the HTTP header Authorization | ||
:2 - Prefix the IAM access token with the literal Bearer: Bearer eyJhbGciOiJSUzI1Ng... | ::2 - Prefix the IAM access token with the literal Bearer: Bearer eyJhbGciOiJSUzI1Ng... | ||
:3 - Add the prefixed IAM access token to the HTTP header: Authorization: Bearer eyJhbGciOiJSUzI1Ng.... | ::3 - Add the prefixed IAM access token to the HTTP header: Authorization: Bearer eyJhbGciOiJSUzI1Ng.... | ||
:</references> | ::<references/> | ||
:Managing user API keys<ref name="key">informatie afkomstig van [https://cloud.ibm.com/docs/account?topic=account-userapikey&interface=ui#userapikey Creating an API key]</ref> | |||
::1 - Ga naar [https://cloud.ibm.com/ Console] | |||
::2 - Klik rechtsboven op <em>Manage</em> | |||
::3 - Klik op <em>Access (IAM)</em> | |||
::4 - Klik in de linker kolom op <em>API keys</em> | |||
::5 - Klik op <em>Create an IBM Cloud API key</em> | |||
::6 - Vul de naam in | |||
::7 - Vul de omschrijving in | |||
::8 - Klik op <em>Create</em> | |||
::9 - Klik op <em>Copy</em> of <em>Download</em> | |||
::<references/> | |||
}} | }} | ||
[[Categorie:Webdesign:Watson]] | [[Categorie:Webdesign:Watson]] |
Huidige versie van 16 aug 2021 om 16:36
Terug naar Webdesign