Skip to content

Commit cd84049

Browse files
authored
Change the instruction on auth and update links (#1101)
* Modify the instruction on project authentication. * As the Teams and Permissions guide will be deleted, and the Identity & Access Management Developer Guide will be used instead, update the links. Relates-To: OLPEDGE-2364, OLPEDGE-2366 Signed-off-by: Halyna Dumych <[email protected]>
1 parent 988d27e commit cd84049

File tree

6 files changed

+65
-33
lines changed

6 files changed

+65
-33
lines changed

docs/GettingStartedGuide.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ For more information, see the [Data User Guide](https://developer.here.com/olp/d
1717

1818
To work with catalog or service requests to the HERE platform, you need to get authentication and authorization credentials.
1919

20-
You can authenticate to the HERE platform within your application with the platform credentials available on the HERE platform Portal by means of the Data SDK for C++ authentication library. For instructions on how to get credentials, see the [related section](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) in the Terms and Permissions User Guide.
20+
You can authenticate to the HERE platform within your application with the platform credentials available on the HERE Portal by means of the Data SDK for C++ authentication library. For the available authentication options, see the [Identity & Access Management Developer Guide](https://developer.here.com/documentation/identity-access-management/dev_guide/index.html).
2121

2222
## Available Components
2323

docs/authenticate.md

Lines changed: 41 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,20 @@
11
# Authenticate to the HERE Platform
22

3-
To authenticate to the HERE platform and start working with HERE Data SDK for C++, you need to get an access token. You can receive it using a [default token provider](#authenticate-using-a-default-token-provider), [project authentication](#authenticate-using-project-authentication), or [federated credentials](#authenticate-using-federated-credentials)
3+
To authenticate to the HERE platform and start working with HERE Data SDK for C++, you need to get an access token. You can receive it using a [default token provider](#authenticate-using-a-default-token-provider), [project authentication](#authenticate-using-project-authentication), or [federated credentials](#authenticate-using-federated-credentials).
4+
5+
> Note: Keep your credentials secure and do not disclose them. Make sure that your credentials are not stored in a way that enables others to access them.
46
57
## Authenticate using a default token provider
68

79
1. Get your platform credentials.
810

9-
For instructions, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
11+
For instructions, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
1012

1113
You get the `credentials.properties` file.
1214

1315
2. Initialize the authentification settings using the **here.access.key.іd** and **here.access.key.secret** from the `credentials.properties` file as `kKeyId` and `kKeySecret` respectively.
1416

15-
> Note: You can also retrieve your credentials from the `credentials.properties` file using the `ReadFromFile` method. For more information, see the [related API documentation](https://developer.here.com/documentation/sdk-cpp/api_reference/classolp_1_1authentication_1_1AuthenticationCredentials.html#a6bfd8347ebe89e45713b966e621dccdd).
17+
> Note: You can also retrieve your credentials from the `credentials.properties` file using the `ReadFromFile` method. For more information, see the [related API documentation](https://developer.here.com/documentation/sdk-cpp/api_reference/classolp_1_1authentication_1_1_authentication_credentials.html#a6bfd8347ebe89e45713b966e621dccdd).
1618
1719
```cpp
1820
olp::authentication::Settings settings({kKeyId, kKeySecret});
@@ -30,40 +32,61 @@ To authenticate to the HERE platform and start working with HERE Data SDK for C+
3032

3133
You get an access token.
3234

33-
You can use the `AuthenticationSettings` object to create the `OlpClientSettings` object. For more information, see the [related](https://developer.here.com/documentation/sdk-cpp/dev_guide/topics/create-olp-client-settings.html) section in the Developer Guide.
35+
You can use the `AuthenticationSettings` object to create the `OlpClientSettings` object. For more information, see the [related section](https://developer.here.com/documentation/sdk-cpp/dev_guide/topics/create-olp-client-settings.html) in the Developer Guide.
3436

3537
## Authenticate using project authentication
3638

37-
1. Create your application and get your API key.
39+
1. Get your platform credentials.
3840

39-
For instructions, see the [Manage Apps](https://developer.here.com/documentation/access-control/user_guide/topics/manage-apps.html) section in the Terms and Permissions User Guide.
41+
For instructions, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
4042

41-
2. Create a function that returns your API key.
42-
3. Set up the `AuthenticationSettings` object with your function that returns the API key.
43+
2. Initialize the `AuthenticationCredentials` class using the **here.access.key.іd** and **here.access.key.secret** from the `credentials.properties` file as `kKeyId` and `kKeySecret` respectively.
4344

44-
> Note: Do not trigger any tasks on `TaskScheduler` as this might result in a deadlock.
45+
> Note: You can also retrieve your credentials from the `credentials.properties` file using the `ReadFromFile` method. For more information, see the [related API documentation](https://developer.here.com/documentation/sdk-cpp/api_reference/classolp_1_1authentication_1_1_authentication_credentials.html#a6bfd8347ebe89e45713b966e621dccdd).
4546
4647
```cpp
47-
olp::client::AuthenticationSettings auth_settings;
48-
auth_settings.api_key_provider =
49-
[](){ return "your-api-key"; };
48+
olp::authentication::AuthenticationCredentials credentials(kKeyId, kKeySecret);
49+
```
50+
51+
3. Create an authentication client.
52+
53+
```cpp
54+
olp::authentication::AuthenticationSettings settings;
55+
settings.task_scheduler = task_scheduler;
56+
settings.network_request_handler = http_client;
57+
authentication::AutnhentucationClient client(settings);
58+
```
59+
60+
4. Create the `SignInProperties` object with your project ID.
61+
62+
```cpp
63+
authentication::SignInProperties signin_properties;
64+
signin_properties.scope = "<project ID>";
65+
```
66+
67+
5. Create the `SignInClient` object.
68+
69+
```cpp
70+
authentication:: SignInClient(AuthenticationCredentials credentials,
71+
SignInProperties properties,
72+
SignInClientCallback callback);
5073
```
5174

5275
You get an access token.
5376

54-
You can use the `AuthenticationSettings` object to create the `OlpClientSettings` object. For more information, see the [related](https://developer.here.com/documentation/sdk-cpp/dev_guide/topics/create-olp-client-settings.html) section in the Developer Guide.
77+
You can use the `AuthenticationSettings` object to create the `OlpClientSettings` object. For more information, see the [related section](https://developer.here.com/documentation/sdk-cpp/dev_guide/topics/create-olp-client-settings.html) in the Developer Guide.
5578

5679
## Authenticate using federated credentials
5780

5881
1. Get your platform credentials.
5982

60-
For instructions, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
83+
For instructions, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
6184

6285
You get the `credentials.properties` file.
6386

6487
2. Initialize the `AuthenticationCredentials` class using the **here.access.key.іd** and **here.access.key.secret** from the `credentials.properties` file as `kKeyId` and `kKeySecret` respectively.
6588

66-
> Note: You can also retrieve your credentials from the `credentials.properties` file using the `ReadFromFile` method. For more information, see the [related API documentation](https://developer.here.com/documentation/sdk-cpp/api_reference/classolp_1_1authentication_1_1AuthenticationCredentials.html#a6bfd8347ebe89e45713b966e621dccdd).
89+
> Note: You can also retrieve your credentials from the `credentials.properties` file using the `ReadFromFile` method. For more information, see the [related API documentation](https://developer.here.com/documentation/sdk-cpp/api_reference/classolp_1_1authentication_1_1_authentication_credentials.html#a6bfd8347ebe89e45713b966e621dccdd).
6790
6891
```cpp
6992
olp::authentication::AuthenticationCredentials credentials(kKeyId, kKeySecret);
@@ -80,7 +103,7 @@ You can use the `AuthenticationSettings` object to create the `OlpClientSettings
80103

81104
4. Get your federated (Facebook or ArcGIS) properties.
82105

83-
You should have at least your federated access token. For the complete list of federated properties, see the [related](https://developer.here.com/documentation/sdk-cpp/api_reference/structolp_1_1authentication_1_1AuthenticationClient_1_1FederatedProperties.html) documentation.
106+
You should have at least your federated access token. For the complete list of federated properties, see the [related documentation](https://developer.here.com/documentation/sdk-cpp/api_reference/structolp_1_1authentication_1_1_authentication_client_1_1_federated_properties.html).
84107

85108
5. Initialize your federated properties.
86109

@@ -91,7 +114,7 @@ You can use the `AuthenticationSettings` object to create the `OlpClientSettings
91114

92115
6. Create the `SignInUserCallback` class.
93116

94-
For more information, see the [`AuthenticationClient` reference documentation](https://developer.here.com/documentation/sdk-cpp/api_reference/classolp_1_1authentication_1_1AuthenticationClient.html)
117+
For more information, see the [`AuthenticationClient` reference documentation](https://developer.here.com/documentation/sdk-cpp/api_reference/classolp_1_1authentication_1_1_authentication_client.html).
95118

96119
7. Create your own token provider using the authentication client created in step 3, your federated credentials, and the `SignInUserCallback` class.
97120

@@ -118,4 +141,4 @@ You can use the `AuthenticationSettings` object to create the `OlpClientSettings
118141
119142
You get an access token. By default, it expires in 24 hours. To continue working with the HERE platform after your token expires, generate a new access token.
120143
121-
You can use the `AuthenticationSettings` object to create the `OlpClientSettings` object.
144+
You can use the `AuthenticationSettings` object to create the `OlpClientSettings` object. For more information, see the [related section](https://developer.here.com/documentation/sdk-cpp/dev_guide/topics/create-olp-client-settings.html) in the Developer Guide.

docs/dataservice-cache-example.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ On this page, find instructions on how to build and run the example project, get
55
Before you run the example project, authorize to the HERE platform:
66

77
1. On the [Apps & keys](https://platform.here.com/admin/apps) page, copy your application access key ID and access key secret.
8-
For instructions on how to get the access key ID and access key secret, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
8+
9+
For instructions on how to get the access key ID and access key secret, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
910

1011
2. In `examples/main.cpp`, replace the placeholders with your access key ID, access key secret, and Here Resource Name (HRN) of the catalog.
1112
**Note:** You can also specify these values using the command line options.
@@ -65,7 +66,7 @@ To authenticate with the HERE platform, you must get platform credentials that c
6566

6667
1. Get your platform credentials.
6768

68-
For instructions, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
69+
For instructions, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
6970

7071
You get the `credentials.properties` file.
7172

docs/dataservice-read-catalog-example.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ On this page, find instructions on how to build and run the example project on d
55
Before you run the example project, authorize to the HERE platform:
66

77
1. On the [Apps & keys](https://platform.here.com/admin/apps) page, copy your application access key ID and access key secret.
8-
For instructions on how to get the access key ID and access key secret, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
8+
9+
For instructions on how to get the access key ID and access key secret, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
910

1011
2. In `examples/main.cpp`, replace the placeholders with your access key ID, access key secret, and Here Resource Name (HRN) of the catalog.
1112
**Note:** You can also specify these values using the command line options.
@@ -68,8 +69,9 @@ To integrate the HERE Data SDK for C++ libraries in the Android example project:
6869
Before you integrate the HERE Data SDK for C++ libraries in the Android example project:
6970

7071
1. Set up the Android environment.
71-
2. In `examples/android/app/src/main/cpp/MainActivityNative.cpp.in`, replace the placeholders with your application access key ID, access key secret, and catalog HRN and specify that the example should run `RunExampleRead`.
72-
For instructions on how to get the access key ID and access key secret, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
72+
2. In `examples/android/app/src/main/cpp/MainActivityNative.cpp.in`, replace the placeholders with your application access key ID, access key secret, and catalog HRN and specify that the example should run `RunExampleRead`.
73+
74+
For instructions on how to get the access key ID and access key secret, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
7375

7476
### <a name="build-sdk-android"></a>Build the HERE Data SDK for C++
7577

@@ -119,9 +121,11 @@ Before you integrate the HERE Data SDK for C++ libraries in the iOS example proj
119121

120122
1. To set up the iOS development environment, install the `XCode` and command-line tools.
121123
2. Install external dependencies.
124+
122125
For information on dependencies and installation instructions, see the [related section](https://github.com/heremaps/here-data-sdk-cpp#dependencies) in the README.md file.
123126
3. In `examples/ios/ViewController.mm`, replace the placeholders with your application access key ID, access key secret, and catalog HRN and specify that the example should run `RunExampleRead`.
124-
For instructions on how to get the access key ID and access key secret, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
127+
128+
For instructions on how to get the access key ID and access key secret, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
125129

126130
### <a name="build-sdk-ios"></a>Build the HERE Data SDK for C++
127131

@@ -169,7 +173,7 @@ To authenticate with the HERE platform, you must get platform credentials that c
169173

170174
1. Get your platform credentials.
171175

172-
For instructions, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
176+
For instructions, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
173177

174178
You get the `credentials.properties` file.
175179

docs/dataservice-read-from-stream-layer-example.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ On this page, you can find instructions on how to build and run the example proj
55
Before you run the example project, authorize to the HERE platform:
66

77
1. On the [Apps & keys](https://platform.here.com/admin/apps) page, copy your application access key ID and access key secret.
8-
For instructions on how to get the access key ID and access key secret, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
8+
9+
For instructions on how to get the access key ID and access key secret, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
910

1011
2. In `examples/main.cpp`, replace the placeholders with your access key ID, access key secret, and Here Resource Name (HRN) of the catalog.
1112
**Note:** You can also specify these values using the command line options.
@@ -65,7 +66,7 @@ To authenticate with the HERE platform, you must get platform credentials that c
6566

6667
1. Get your platform credentials.
6768

68-
For instructions, see the [Get Credentials](https://developer.here.com/olp/documentation/access-control/user-guide/topics/get-credentials.html) section in the Terms and Permissions User Guide.
69+
For instructions, see the [Register Your Application](https://developer.here.com/documentation/identity-access-management/dev_guide/topics/plat-token.html#step-1-register-your-application) section in the Identity & Access Management Developer Guide.
6970

7071
You get the `credentials.properties` file.
7172

0 commit comments

Comments
 (0)