Managing Data Marketplace Contexts via the Command Line
You can use the SAP Datasphere command line interface, datasphere, to create and manage Data Marketplace contexts.
Prerequisites
-
Data Warehouse General (-R------) - To access SAP Datasphere.
-
Data Warehouse Data Builder (CRUD---S) - To create, edit and delete data providers.
-
Space Files (CRUD----) - To create, read, update, and delete marketplace objects in your spaces.
-
Spaces (-RU-----) - To modify the space properties.
-
Install the datasphere command line interface (see Install or Update the SAP Datasphere Command Line Interface).
-
Log in to your SAP Datasphere tenant (see Log into the Command Line Interface via an OAuth Client).
Use contexts to restrict the visibility of your data provider profile and your data products to selected users only. For more information about Data Marketplace contexts, see Using Contexts to Realize Public, Private, and Internal Offers.
datasphere marketplace contexts-by-provider list
Returns a list of contexts for a data provider.
datasphere marketplace contexts-by-provider list
|
Parameter |
Description |
|---|---|
|
--accept <accept> |
Format to return the content in.
Choices:
|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
datasphere marketplace contexts-by-provider create
Creates a new context for a specified data provider, based on a configuration following the context definition file format and stored as a .json file. For more information, see the Data Sharing Cockpit
documentation in the SAP Business Accelerator Hub.
datasphere marketplace contexts-by-provider create
Specify the full path to the input .json file, for example C:\temp\mycontextdefinition.json.
The new context is created in status Draft. You can activate the context with the command datasphere marketplace context-by-provider change-lifecycle-status.
|
Parameter |
Description |
|---|---|
|
--file-path <path> |
Enter a path to a file with a .json extension containing your context definition. |
|
--input <input> |
Specifies input as string to use for the command (optional). |
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
datasphere marketplace contexts-by-provider read
Lists the properties of a context for a specific data provider. You must specify the context UUID and the data provider UUID.
datasphere marketplace contexts-by-provider read
|
Parameter |
Description |
|---|---|
|
--context-identifier <context-identifier> |
Context UUID. |
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
datasphere marketplace contexts-by-provider update
Updates selected properties of a specified context, based on a configuration following the context definition file format and stored as a .json file. For more information, see the Data Sharing Cockpit
documentation in the SAP Business Accelerator Hub.
datasphere marketplace contexts-by-provider update
|
Parameter |
Description |
|---|---|
|
--file-path <path> |
Enter a path to a file with a .json extension containing your context definition. |
|
--input <input> |
Specifies input as string to use for the command (optional). |
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--context-identifier <context-identifier> |
Context UUID. |
datasphere marketplace contexts-by-provider overwrite
Overwrites all properties of the specified context with the provided data in the context definition file. For more information, see the Data Sharing Cockpit
documentation in the SAP Business Accelerator Hub.
datasphere marketplace contexts-by-provider overwrite
|
Parameter |
Description |
|---|---|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--context-identifier <context-identifier> |
Context UUID. |
|
--file-path <path> |
Enter a path to a file with a .json extension containing your context definition. |
|
--input <input> |
Specifies input as string to use for the command (optional). |
datasphere marketplace contexts-by-provider delete
Deletes an existing context of a specified data provider.
datasphere marketplace contexts-by-provider delete
|
Parameter |
Description |
|---|---|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--context-identifier <context-identifier> |
Context UUID. |
datasphere marketplace contexts-by-provider change-lifecycle-status
Changes the lifecycle status of a context to Active. A newly created context is automatically set to status Draft: before consumers can use their activation keys to join a context in the Data Marketplace, you have to activate the context.
datasphere marketplace contexts-by-provider change-lifecycle-status
|
Parameter |
Description |
|---|---|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--context-identifier <context-identifier> |
Context UUID. |
datasphere marketplace contexts-by-provider join
With this command you join an existing context, based on a configuration following the context definition file format and stored as a .json file. For more information, see the Data Sharing Cockpit
documentation in the SAP Business Accelerator Hub. . After joining you can see all data products listed in this context.
datasphere marketplace contexts-by-provider join
|
Parameter |
Description |
|---|---|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--file-path <path> |
Enter a path to a file with a .json extension containing your context definition. |
|
--input <input> |
Specifies input as string to use for the command (optional). |
datasphere marketplace contexts-by-provider leave
With this command you leave a context, based on a configuration following the context definition file format and stored as a .json file. For more information, see the Data Sharing Cockpit
documentation in the SAP Business Accelerator Hub. . If you leave a context, you won't be able to see the data products listed in this context anymore.
datasphere marketplace contexts-by-provider leave
|
Parameter |
Description |
|---|---|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--file-path <path> |
Enter a path to a file with a .json extension containing your context definition. |
|
--input <input> |
Specifies input as string to use for the command (optional). |
datasphere marketplace contexts-by-provider keys list
Returns a list of all the existing activation keys for a specified context.
datasphere marketplace contexts-by-provider keys list
|
Parameter |
Description |
|---|---|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--context-identifier <context-identifier> |
Context UUID. |
datasphere marketplace contexts-by-provider keys generate
Generates activation keys for a specified context, based on a configuration following the context definition file format and stored as a .json file. For more information, see the Data Sharing Cockpit
documentation in the SAP Business Accelerator Hub. .
datasphere marketplace contexts-by-provider keys generate
|
Parameter |
Description |
|---|---|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--context-identifier <context-identifier> |
Context UUID. |
|
--file-path <path> |
Enter a path to a file with a .json extension containing your context definition. |
|
--input <input> |
Specifies input as string to use for the command (optional). |
datasphere marketplace contexts-by-provider keys delete
Deletes an activation key from a specified context, based on a configuration following the context definition file format and stored as a .json file. For more information, see the Data Sharing Cockpit
documentation in the SAP Business Accelerator Hub. .
datasphere marketplace contexts-by-provider keys delete
|
Parameter |
Description |
|---|---|
|
--provider-identifier <provider-identifier> |
Provider identifier.
You can either:
|
|
--context-identifier <context-identifier> |
Context UUID. |
|
--file-path <path> |
Enter a path to a file with a .json extension containing your context definition. |
|
--input <input> |
Specifies input as string to use for the command (optional). |