service

The OLP CLI supports the following functionality for HERE Location Services:

service list

Lists all location services that you are allowed to access.

olp service list [command options]

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 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 service HRNs, each on a new line.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

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

Example:

The command below lists all the services to which you have access.

olp service list --json

Output:


{"services": [
    {
        "owner": {
            "creator": "Ru9zEteKdJLTyMf8pDDT",
            "organisation": "org"
        },
        "summary": "The service example for demonstration purposes.",
        "baseUrl": "https://location-service-demo.services.api.platform.here.com",
        "metadata": {
             "environment": "Dev",
             "momVersion": "2.0.1",
             "contentDomain": "Vehicle Routing",
             "odinId": "3473"
        },
        "protocol": "REST",
        "hrn": "hrn:here-cn:service::org:location-service-demo-1",
        "created": "2019-08-06T13:35:50.94598Z",
        "name": "Location Service Demo",
        "state": "Running",
        "dataSources": [{
            "owner": "HERE",
            "schema": "HERE example",
            "name": "HERE example",
            "description": "HERE example data"
            "hrn": "SPACE-ID",
            "kind": "INPUT",
            "type": "DATAHUB",
            "layer": [
                "olp-streaming-layer3",
                "olp-streaming-layer2",
                "olp-streaming-layer1"
            ]
        }],
        "updated": "2019-08-06T13:35:50.94598Z",
        "version": "1.0.0",
        "tags": [
            "HERE",
            "EXAMPLE"
        ]
    }
]}

service show

Shows the properties of a specified location service.

olp service show <service HRN> [command options]

Required parameters:

  • <service HRN> The HRN of the service to show.

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 platform portal.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --json Displays the service properties in JSON format.
  • --quiet Displays the service HRN.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

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

Example:

The command below displays the properties of the specified service.


olp service show hrn:here-cn:service::org:open-vehicle-routing-0 --json

Output:


{
    "owner": {
        "creator": "QoagGAKgreOKSlypB8M8",
        "organisation": "org"
    },
    "summary": "The Routing - Vehicle service end point calculates routes between two or more locations using various transport modes and provides additional route-related information. The Routing API is customizable so that the route calculation and additional information can be adapted to both consumer and enterprise applications.",
    "baseUrl": "https://vehicle.router.hereapi.com/v0",
    "metadata": {
                "environment": "Dev",
                "momVersion": "2.0.1",
                "contentDomain": "Vehicle Routing",
                "odinId": "3473"
     },
    "protocol": "REST",
    "hrn": "hrn:here-cn::org:routing-vehicle-0",
    "created": "2019-08-06T12:39:00.441365Z",
    "name": "Routing - Vehicle",
    "state": "Running",
    "dataSources": [{
        "owner": "HERE",
        "name": "Here Map Content"
        "schema": "HMC Map Content",
        "hrn": "SPACE-ID",
        "kind": "INPUT",
        "description": "Places layer from the HERE Map Content catalog.",
        "type": "DATAHUB",
        "layer": [
             "olp-streaming-layer3",
             "olp-streaming-layer2",
             "olp-streaming-layer1"
         ]
    }],
    "updated": "2019-08-06T12:39:00.441365Z",
    "version": "1.0.0",
    "tags": [
        "Navigation",
        "Directions",
        "Traffic",
        "Route"
    ]
}

service version list

Lists versions of the specified location service.

olp service version list <service HRN> [command options]

Required parameters:

  • <service HRN> The HRN of the service to list versions.

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 platform portal.
  • --profile <profile name> The name of the credentials profile to use from the olpcli.ini file.
  • --json Displays the service versions list in JSON format.
  • --quiet Displays the service versions.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

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

Example:

The command below displays a list of versions of the specified service.


olp service version list hrn:here-cn:service::org:open-vehicle-routing-0 --json

Output:


{"serviceVersions": [
    {
        "versionDescription": "Update message 4",
        "version": "3.1.3",
        "updated": "2019-10-11T12:32:41.970332Z"
    },
    {
        "versionDescription": "Update message 3",
        "version": "3.1.2",
        "updated": "2019-10-11T12:31:22.436954Z"
    },
    {
        "versionDescription": "Update message 2",
        "version": "3.1.1",
        "updated": "2019-10-04T13:44:21.514794Z"
    }
]}

service manifest show

Show the manifest for a particular service

olp service manifest show <service HRN> [command options]

Required parameters:

  • <service HRN> The HRN of the service to show the manifest for.

Optional parameters:

  • --credentials The name of a credentials file to use with the command. Credentials files are downloaded separately from the OLP Portal.
  • --profile The name of the credentials profile to use from the olpcli.ini file.
  • --quiet Display the service HRN.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

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

Example:

The command below show the manifest file.

olp service manifest {{book.filtered.hrnPrefix}}:service::org:open-vehicle-routing-0

Output:

    manifest: 0.0.2

    id: add-test-${unique-value}-15
    name: Add test ${unique-value}
    label: "(private beta)"
    notice: "This service is currently being tested and is not yet available for public use."
    summary: >-
      The HERE Geocode service converts street addresses to geo-coordinates and vice-versa with forward geocoding, including landmarks and
      reverse geocoding. Intention is to find a specific location, not a list of potentially interesting places.
    base-url: https://hereapi.com
    tags:
      - SEARCH
      - HERE
      - PLACES
      - POIS
    version: 15.2.1
    data-sources:
      - name: HERE Places
        owner: HERE
        description: Places layer from the HERE Map Content catalog.
        schema: HMC Places
    data-sources-notice: Want to use your own data? We can help you import and prepare it.
    deployments:
      - region: us-east-1
        workers-count: 2
        worker-size: 10
      - region: eu-west-1
        workers-count: 3
        worker-size: 5
    developer-guide-url: https://here-tech.skawa.fun/olp/documentation/

service openapi show

Show the OpenApi specification for a particular service.

olp service openapi show <service HRN> [command options]

Required parameters:

  • <service HRN> The HRN of the service to show the OpenAPI file for..

Optional parameters:

  • --credentials The name of a credentials file to use with the command. Credentials files are downloaded separately from the OLP Portal.
  • --profile The name of the credentials profile to use from the olpcli.ini file.
  • --quiet Display the service HRN.
  • --scope <project HRN> Specifies the project HRN to use as the scope in the request. The value specified with --scope overrides any value for here.token.scope provided in the credentials file used for the command.

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

Example:

The command below shows the OpenAPI file for a service.

olp service openapi {{book.filtered.hrnPrefix}}:service::org:open-vehicle-routing-0

Output:

openapi: 3.0.2
servers:
  - description: Apisprout Auto Mocking
    url: 'http://olp-docs.ad.here.com:5000'
  - url: 'http://localhost:8888'
    variables: {}
info:
  description: The service provides service management operations.
  version: 1.0.0
  title: Service API v1
  license:
    name: 'https://confluence.in.here.com/display/TEW/Describe+Your+API'
tags:
  - name: service
    description: Manage services
    externalDocs:
      description: Find out more
      url: 'http://here.com'
paths:
  /services:
    get:
      tags:
        - service
      summary: Get a list of all services
      description: Lists all available services.
      operationId: getServices
      responses:
        '200':
          description: Successful operation.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Service'
        '401':
          description: Unathorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'

results matching ""

    No results matching ""