app domain
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:
--domainA 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 theolpcli.inifile.--quietDisplays 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:account::org:app/my-app-1234 --domain https://example.comOutput:
Trusted domain https://example.com added to app hrn:here:account::org:app/my-app-1234app 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 theolpcli.inifile.--quietDisplays 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:account::org:app/my-app-1234 https://example.comOutput:
App hrn:here:account::org:app/my-app-1234 has trusted domain https://example.comapp 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 theolpcli.inifile.--jsonDisplays a list of services in JSON format.--quietDisplays 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:account::org:app/my-app-1234 --jsonOutput:
{"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 theolpcli.inifile.--quietDisplays 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.
olp domain delete hrn:here:account::org:app/my-app-1234
\ --domain-list path/to/fileolp domain delete hrn:here:account::org:app/my-app-1234
^ --domain-list path/to/fileOutput:
The output when all domains are deleted:
Trusted domains deleted from app hrn:here:account::org:app/my-app-1234The 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
}
]
}Updated 21 days ago