A.1.2 How to obtain the URL for REST API for OML Services, REST API for OML4Py and OML4R embedded execution from the Autonomous AI Database ?
To obtain the OML URL, SQL Developer URL, Graph Studio URL, APEX URL
You can obtain the Oracle Machine Learning User Management URL for a specific tenancy from the Oracle Cloud Infrastructure
(OCI) command line. You must first obtain the tenancy ID.
- To obtain the tenancy ID, go to your OCI Profile on the top right corner of the Oracle Cloud page and click Tenancy.
- On the Tenancy details page, click Copy to obtain the tenancy URL.
- Type the following command in your OCI command line
interface:
oci db database list --compartment-id <tenancy OCID>
Here,compartment-id:
This is the unique ID assigned to your compartment.OCID:
This is the Oracle Cloud Identifier (OCID) for your tenancy.
- This command returns the following:
"connection-urls": { "apex-url": https://<tenancy ID>-<database name>.<region>.oraclecloudapps.com/ords/apex, "graph-studio-url": https://<tenancy ID>-<database name>.<region>.oraclecloudapps.com/graphstudio/, "machine-learning-user-management-url": https://<tenancy ID>-<database name>.<region>-1.oraclecloudapps.com/omlusers/, "sql-dev-web-url": https://<tenancy ID>-<database name>.<region>-1.oraclecloudapps.com/ords/sql-developer },
For more information, see Access OML User Management from Command Line
To obtain the URLs for OML User Management, REST API OML Services, REST API for OML4Py and OML4R embedded execution from Command Line or Autonomous AI Database
Use the view
v$pdbs
and run the
following:select 'https://' ||
lower(REPLACE(p.name, '_', '-')) ||
'.' ||
REGEXP_REPLACE(j.PUBLIC_DOMAIN_NAME, '[^.]+', 'oraclecloudapps', 1, 3) ||
'/omlusers/' auth_token_url,
'https://' ||
lower(REPLACE(p.name, '_', '-')) ||
'.' ||
REGEXP_REPLACE(j.PUBLIC_DOMAIN_NAME, '[^.]+', 'oraclecloudapps', 1, 3) ||
'/oml/' embed_python_r_url,
'https://' ||
lower(REPLACE(p.name, '_', '-')) ||
'.' ||
REGEXP_REPLACE(j.PUBLIC_DOMAIN_NAME, '[^.]+', 'oraclecloudapps', 1, 3) ||
'/omlmod/' rest_services_url
from v$pdbs p,
json_table(p.cloud_identity, '$' columns (
PUBLIC_DOMAIN_NAME path '$.PUBLIC_DOMAIN_NAME'
)) j;
This command works for non-private endpoint databases. Users that create their own URL behind a private endpoint could modify it.
This query returns three URLs:
- OML User Management URL (same as returned by OCI CLI)
- URL for OML4Py and OML4R embedded execution
- URL for OML Services REST APIs
To obtain the URL for OML REST Services from the Autonomous AI Database
You can see the URLs for your database in Database Actions
- On your Oracle Autonomous AI Database console, click Database actions, and then select the option View all database actions.
- Click RESTFul Services and then click Oracle Machine Learning RESTful services. The Oracle Machine Learning RESTful Services dialog opens.
- On the Oracle Machine Learning RESTful Services dialog, copy the URL for your ADB instance.
For more information, see Task 2: Get the OML Services URL to Obtain Your REST Authentication Token
Parent topic: FAQs