watsonx_ai service has 7 resource kinds, each listed below with its endpoints, fields, and dependencies. Values resolve late, so you reference another resource with ${kind.ref_name}. For defaults, validation rules, and examples, run wxctl explain <kind>.
YAML envelope & reference syntax
YAML envelope & reference syntax
- Envelope: A config is one or more YAML documents separated by
---. Each has top-levelkindandref_name, then the fields below at the top level (not nested underspec). ref_name: Unique handle for this resource within the config. Used to reference it from other resources, then stripped before the API call (not a schema field).- References: Reference another resource by its ref_name:
${<kind>.<ref_name>}resolves to its id,${<kind>.<ref_name>.<field>}to a specific field. Values resolve late, at plan/apply time.
ai_service
An AI Service is a deployable code artifact for Watson Machine Learning.
Runs on SaaS + Software · ID field id
Endpoints
| Operation | Method | Path |
|---|---|---|
| Create | POST | /ml/v4/ai_services?version=2024-01-01 |
| Read | GET | /ml/v4/ai_services/{id}?version=2024-01-01 |
| List | GET | /ml/v4/ai_services?version=2024-01-01 |
| Update | PATCH | /ml/v4/ai_services/{id}?version=2024-01-01 |
| Delete | DELETE | /ml/v4/ai_services/{id}?version=2024-01-01 |
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Required | Name of the AI service. |
description | string | Optional | Human-readable description. |
tags | array<string> | Optional | Tags for categorization. |
software_spec | string | Required | Software specification ID. References a software_specification resource. |
space_id | string | Optional | The space ID scope. Sent in body on create, used as query param on list/get/delete. |
project_id | string | Optional | The project ID scope. Sent in body on create, used as query param on list/get/delete. |
custom | object | Optional | Arbitrary key-value metadata. |
source_path | string | Optional | Local path to Python source file. Used by the post_create hook to upload code. |
id, created_at.
Depends on
software_spec→software_specification(required)space_id→space(optional)project_id→project(optional)
wml_deployment→.asset(required)
autoai_experiment
An AutoAI Experiment runs a watsonx.ai AutoAI training to completion and surfaces the ranked pipeline leaderboard.
Runs on SaaS + Software · ID field id
Endpoints
| Operation | Method | Path |
|---|---|---|
| Create | POST | /ml/v4/trainings?version=2024-01-01 |
| Read | GET | /ml/v4/trainings/{id}?version=2024-01-01 |
| List | GET | /ml/v4/trainings?version=2024-01-01 |
| Delete | DELETE | /ml/v4/trainings/{id}?version=2024-01-01&hard_delete=true |
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Required | Experiment / training run name. |
training_data | string | Required | Asset id of the training data (a data_asset). Used to build the training’s training_data_references entry (type: data_asset). |
prediction_type | string | Required | AutoAI learning task type. |
prediction_column | string | Optional | Target/label column name for a tabular experiment. Required for binary/multiclass/regression; omit for forecasting (use prediction_columns). Exactly one of prediction_column / prediction_columns must be set. |
prediction_columns | array<string> | Optional | Target/label column names for a forecasting experiment (one entry per series). Mutually exclusive with the tabular prediction_column: exactly one of the two must be set. Emitted as optimization.target_columns in the TS pipeline document. |
timestamp_column | string | Optional | Name of the timestamp column ordering the series (forecasting only). Emitted as optimization.timestamp_column. |
lookback_window | integer | Optional | Number of past time steps the model reads to produce a forecast (forecasting only). Emitted as optimization.lookback_window. |
forecast_window | integer | Optional | Number of future time steps to predict, the forecast horizon (forecasting only). Emitted as optimization.prediction_horizon. |
backtest_num | integer | Optional | Number of backtest folds used to evaluate the forecasting pipelines. Emitted as optimization.num_backtest. |
scoring | string | Optional | Optimization metric (scorer_for_ranking), e.g. accuracy / roc_auc / neg_root_mean_squared_error. Omit to let AutoAI choose the default for the prediction_type. |
holdout_size | float | Optional | Holdout fraction (0.0–1.0) carried into optimization.holdout_param. |
include_only_estimators | array<string> | Optional | Restrict AutoAI to these estimator names (optional). |
t_shirt_size | string | Optional | Compute size for the AutoAI run (cluster default if omitted). |
space_id | string | Optional | The space ID scope. Sent in body on create, query param on get/list/delete. |
project_id | string | Optional | The project ID scope. Sent in body on create, query param on get/list/delete. |
generation | integer | Optional | Optional re-run nonce (Kubernetes metadata.generation semantics). Bump this to launch a new run with all other inputs unchanged; it is folded into the identity hash and never sent to the API body. Prior generations are retained. |
id, pipeline_id, state, best_pipeline, leaderboard.
Depends on
training_data→data_asset(required)space_id→space(optional)project_id→project(optional)
wml_model→.experiment(required)
notebook
A Notebook asset stored in a watsonx.ai project.
Runs on SaaS + Software · ID field guid
Endpoints
| Operation | Method | Path |
|---|---|---|
| Create | POST | /v2/assets |
| Read | GET | /v2/assets/{guid} |
| List | GET | /v2/asset_types/notebook/search |
| Delete | DELETE | /v2/assets/{guid} |
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Required | Notebook name (the .ipynb basename in the project). |
source_path | string | Required | Local path to the .ipynb file. Resolved against the config file’s directory. |
environment | string | Optional | The notebook runtime environment guid. |
project_id | string | Optional | The project ID scope. |
guid, created_at.
Depends on
environment→environment(optional)project_id→project(optional)
job→.asset(optional)
wml_deployment
A WML Deployment creates a live online endpoint from an AI service or model.
Runs on SaaS + Software · ID field id
Endpoints
| Operation | Method | Path |
|---|---|---|
| Create | POST | /ml/v4/deployments?version=2024-01-01 |
| Read | GET | /ml/v4/deployments/{id}?version=2024-01-01 |
| List | GET | /ml/v4/deployments?version=2024-01-01 |
| Update | PATCH | /ml/v4/deployments/{id}?version=2024-01-01 |
| Delete | DELETE | /ml/v4/deployments/{id}?version=2024-01-01 |
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Required | Deployment name. |
description | string | Optional | Human-readable description. |
tags | array<string> | Optional | Tags for categorization. |
asset | string | Required | ID of the asset to deploy. Can reference an ai_service, wml_function, wml_script, wml_model, or a promoted asset_promotion (${asset_promotion.x.id}) resource. Immutable, pointing a deployment at a different asset requires destroy + recreate. |
space_id | string | Optional | The space ID scope. Sent in body on create, used as query param on list/get/delete. |
project_id | string | Optional | The project ID scope. Sent in body on create, used as query param on list/get/delete. |
online | object | Optional | Online deployment configuration. Can be empty ({}) for defaults. |
batch | object | Optional | Batch deployment configuration. Can be empty ({}) for defaults. Mutually exclusive with online, a deployment is either online or batch. |
hardware_spec | object | Optional | Hardware specification for the deployment. |
custom | object | Optional | Arbitrary key-value metadata. |
id, created_at, status, scoring_url.
Depends on
asset→ai_service(required)asset→wml_function(optional)asset→wml_script(optional)asset→wml_model(optional)asset→asset_promotion(optional)space_id→space(optional)project_id→project(optional)
model→.provider_config.watsonx_deployment_id(optional)subscription→.asset.asset_id(required)subscription→.deployment.deployment_id(required)
- warn (doc_cited, 2026-06-12): A watsonx.ai online deployment (wml_deployment) is scoped to a deployment space, not a project. Using a common_core_project as the deployment container does not work: the deployment, its software specification, and its function all expect a space id, and a project reference cannot supply one. Create the deployable asset and its deployment inside a common_core_space.
wml_function
A Python function asset stored in Watson Machine Learning.
Runs on SaaS + Software · ID field id
Endpoints
| Operation | Method | Path |
|---|---|---|
| Create | POST | /ml/v4/functions?version=2024-01-01 |
| Read | GET | /ml/v4/functions/{id}?version=2024-01-01 |
| List | GET | /ml/v4/functions?version=2024-01-01 |
| Update | PATCH | /ml/v4/functions/{id}?version=2024-01-01 |
| Delete | DELETE | /ml/v4/functions/{id}?version=2024-01-01 |
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Required | Function name. |
description | string | Optional | Human-readable description. |
tags | array<string> | Optional | Tags for categorization. |
software_spec | string | Required | Software specification ID. References a software_specification asset. |
space_id | string | Optional | The space ID scope. Sent in body on create, used as query param on list/get/delete. |
project_id | string | Optional | The project ID scope. Sent in body on create, used as query param on list/get/delete. |
custom | object | Optional | Arbitrary key-value metadata. |
source_path | string | Optional | Local path to Python source file. Used by the post_create hook to upload code. |
id, created_at.
Depends on
software_spec→software_specification(required)space_id→space(optional)project_id→project(optional)
model_tracking→.model(optional)wml_deployment→.asset(optional)
wml_model
A WML Model materializes the winning pipeline of a completed AutoAI experiment as a deployable wml-hybrid_0.1 model.
Runs on SaaS + Software · ID field id
Endpoints
| Operation | Method | Path |
|---|---|---|
| Create | POST | /ml/v4/models?version=2024-01-01 |
| Read | GET | /ml/v4/models/{id}?version=2024-01-01 |
| List | GET | /ml/v4/models?version=2024-01-01 |
| Delete | DELETE | /ml/v4/models/{id}?version=2024-01-01 |
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Required | Model name (shown in the space catalog; the deployable asset name). |
experiment | string | Required | Training id of the completed autoai_experiment whose winning pipeline is materialized. The handler reads its results_reference + leaderboard. |
pipeline_name | string | Optional | Which AutoAI pipeline to materialize. best (default) resolves to the top-ranked leaderboard pipeline node; an explicit Pipeline_N selects a specific node. |
space_id | string | Optional | The space ID scope. Sent in body on create, query param on get/list/delete. |
project_id | string | Optional | The project ID scope. Sent in body on create, query param on get/list/delete. |
id, model_type, pipeline_node, created_at.
Depends on
experiment→autoai_experiment(required)space_id→space(optional)project_id→project(optional)
model_tracking→.model(required)wml_deployment→.asset(optional)
wml_script
A Python script asset stored in Watson Machine Learning.
Runs on SaaS + Software · ID field id
Endpoints
| Operation | Method | Path |
|---|---|---|
| Create | POST | /ml/v4/functions?version=2024-01-01 |
| Read | GET | /ml/v4/functions/{id}?version=2024-01-01 |
| List | GET | /ml/v4/functions?version=2024-01-01 |
| Update | PATCH | /ml/v4/functions/{id}?version=2024-01-01 |
| Delete | DELETE | /ml/v4/functions/{id}?version=2024-01-01 |
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Required | Script name. |
description | string | Optional | Human-readable description. |
tags | array<string> | Optional | Tags for categorization. |
software_spec | string | Required | Software specification ID. References a software_specification asset. |
space_id | string | Optional | The space ID scope. Sent in body on create, used as query param on list/get/delete. |
project_id | string | Optional | The project ID scope. Sent in body on create, used as query param on list/get/delete. |
custom | object | Optional | Arbitrary key-value metadata. |
source_path | string | Optional | Local path to Python source file. Used by the post_create hook to upload code. |
id, created_at.
Depends on
software_spec→software_specification(required)space_id→space(optional)project_id→project(optional)
wml_deployment→.asset(optional)

