app domain

The OLP CLI supports the following platform API commands:

  • add one or more trusted domains to an application. A maximum of 3,000 trusted domains per application are allowed.
  • show if a trusted domain is associated with an application.
  • list trusted domains associated with an application.
  • delete one or more trusted domains associated with an application.

app domain add

Adds one, or more, trusted domains to an app.

olp app domain add <app HRN> [command options]

Required parameters:

  • <app HRN> The HRN of the application.
  • Either of the following parameters:
    • --domain A trusted domain.
    • --domain-list <path to file> A comma-separated list (CSV) file containing trusted domains separated by a comma or new-line.

Optional parameters:

  • --credentials <path to credentials file> The name of a credentials file to use with the command. Credentials files are downloaded separately from the HERE platform portal.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --quiet Displays empty output with no additional information.

For more information on using credentials and profiles, see Credentials setup.

Example:

The command below adds a domain to an application.


olp app domain add hrn:here-cn:account::org:app/my-app-1234 --domain https://example.com

Output:


Trusted domain https://example.com added to app hrn:here-cn:account::org:app/my-app-1234

app domain show

Shows if there are trusted domains associated with an app.

olp app domain show <app HRN> <trusted domain URI> [command options]

Required parameters:

  • <app HRN> The HRN of the application.
  • <trusted domain URI> The domain URI for the application.

Optional parameters:

  • --credentials <path to credentials file> The name of a credentials file to use with the command. Credentials files are downloaded separately from the HERE platform portal.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --quiet Displays empty output with no additional information.

For more information on using credentials and profiles, see Credentials setup.

Example:

The command below shows if a trusted domain is associated with an application.


olp app domain show hrn:here-cn:account::org:app/my-app-1234 https://example.com

Output:


App hrn:here-cn:account::org:app/my-app-1234 has trusted domain https://example.com

app domain list

Lists all trusted domains associated with an application.

olp app domain list <app HRN> [command options]

Required parameters:

  • <app HRN> The HRN of the application.

Optional parameters:

  • --credentials <path to credentials file> The name of a credentials file to use with the command. Credentials files are downloaded separately from the HERE platform portal.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --json Displays a list of services in JSON format.
  • --quiet Displays the trusted domains, each on a new line.

For more information on using credentials and profiles, see Credentials setup.

Example:

The command below lists trusted domains for an app.


olp app domain list hrn:here-cn:account::org:app/my-app-1234 --json

Output:


{"trustedDomains": [{
"http://example.com",
"https://example.com"
}]}

app domain delete

Deletes one, or many, trusted domains associated with an app.

olp app domain delete <app HRN> [command options]

Required parameters:

  • <app HRN> The HRN of the application.
  • Either of the following parameters:
    • --domain <domain name> A trusted domain
    • --domain-list <path to file> A comma-separated list (CSV) file containing trusted domains separated by a comma or new-line.

Optional parameters:

  • --credentials <path to credentials file> The name of a credentials file to use with the command. Credentials files are downloaded separately from the HERE platform portal.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --quiet Displays empty output with no additional information.

For more information on using credentials and profiles, see Credentials setup.

Example:

The command below deletes many domains associated with the application.

Linux
Windows
olp domain delete hrn:here-cn:account::org:app/my-app-1234
\ --domain-list path/to/file
olp domain delete hrn:here-cn:account::org:app/my-app-1234
^ --domain-list path/to/file

Output:

The output when all domains are deleted:


Trusted domains deleted from app hrn:here-cn:account::org:app/my-app-1234

The output example when there was an error deleting a domain:


{
"items" : [ {
"trustedDomain" : "example.com",
"status" : 204
}, {
"trustedDomain" : "https://foo.com",
"status" : 204
}, {
"trustedDomain" : "http://bar.com:8080/path",
"status" : 400367
} ]
}

results matching ""

    No results matching ""