Last updated: January 14, 2025
DQOps REST API dictionaries operations
Operations for managing data dictionary CSV files in DQOps. Data dictionaries can be used in accepted_values data quality checks.
create_dictionary
Creates (adds) a new data dictionary CSV file, which creates a file in the DQOps user's home dictionaries/ folder named as the dictionary and with the content that is provided in this call.
Follow the link to see the source code on GitHub.
POST
Request body
Description | Data type | Required |
---|---|---|
Data dictionary model | DataDictionaryModel |
Usage examples
Execution
Execution
from dqops import client
from dqops.client.api.dictionaries import create_dictionary
from dqops.client.models import DataDictionaryModel
dqops_client = client.Client(
'http://localhost:8888/'
)
request_body = DataDictionaryModel(
dictionary_name='sample_dictionary',
file_content='USD
EUR
GBP
AUD
CHF
'
)
call_result = create_dictionary.sync(
client=dqops_client,
json_body=request_body
)
Execution
from dqops import client
from dqops.client.api.dictionaries import create_dictionary
from dqops.client.models import DataDictionaryModel
dqops_client = client.Client(
'http://localhost:8888/'
)
request_body = DataDictionaryModel(
dictionary_name='sample_dictionary',
file_content='USD
EUR
GBP
AUD
CHF
'
)
call_result = await create_dictionary.asyncio(
client=dqops_client,
json_body=request_body
)
Execution
from dqops import client
from dqops.client.api.dictionaries import create_dictionary
from dqops.client.models import DataDictionaryModel
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token
)
request_body = DataDictionaryModel(
dictionary_name='sample_dictionary',
file_content='USD
EUR
GBP
AUD
CHF
'
)
call_result = create_dictionary.sync(
client=dqops_client,
json_body=request_body
)
Execution
from dqops import client
from dqops.client.api.dictionaries import create_dictionary
from dqops.client.models import DataDictionaryModel
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token
)
request_body = DataDictionaryModel(
dictionary_name='sample_dictionary',
file_content='USD
EUR
GBP
AUD
CHF
'
)
call_result = await create_dictionary.asyncio(
client=dqops_client,
json_body=request_body
)
delete_dictionary
Deletes a data dictionary CSV file from the DQOps user's home dictionaries/ folder.
Follow the link to see the source code on GitHub.
DELETE
Parameters of this method are described below
Property name | Description | Data type | Required |
---|---|---|---|
dictionary_name |
Data dictionary name | string |
Usage examples
Execution
Execution
Execution
Execution
download_dictionary
Downloads a data dictionary CSV file
Follow the link to see the source code on GitHub.
GET
Parameters of this method are described below
Property name | Description | Data type | Required |
---|---|---|---|
dictionary_name |
Data dictionary CSV file name | string |
Usage examples
Execution
Execution
Execution
Execution
from dqops import client
from dqops.client.api.dictionaries import download_dictionary
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token,
raise_on_unexpected_status=True
)
call_result = download_dictionary.sync(
'status_codes.csv',
client=dqops_client
)
Execution
from dqops import client
from dqops.client.api.dictionaries import download_dictionary
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token,
raise_on_unexpected_status=True
)
call_result = await download_dictionary.asyncio(
'status_codes.csv',
client=dqops_client
)
get_all_dictionaries
Returns a list of all data dictionary CSV files that are present in the DQOps user's home dictionaries/ folder.
Follow the link to see the source code on GitHub.
GET
Return value
Property name | Description | Data type |
---|---|---|
data_dictionary_list_model |
List[DataDictionaryListModel] |
Usage examples
Execution
Execution
Execution
Execution
Execution
from dqops import client
from dqops.client.api.dictionaries import get_all_dictionaries
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token,
raise_on_unexpected_status=True
)
call_result = await get_all_dictionaries.asyncio(
client=dqops_client
)
get_dictionary
Returns the content of a data dictionary CSV file as a model object
Follow the link to see the source code on GitHub.
GET
Return value
Property name | Description | Data type |
---|---|---|
data_dictionary_model |
DataDictionaryModel |
Parameters of this method are described below
Property name | Description | Data type | Required |
---|---|---|---|
dictionary_name |
Data dictionary CSV file name | string |
Usage examples
Execution
Execution
Execution
Execution
from dqops import client
from dqops.client.api.dictionaries import get_dictionary
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token,
raise_on_unexpected_status=True
)
call_result = get_dictionary.sync(
'status_codes.csv',
client=dqops_client
)
Execution
from dqops import client
from dqops.client.api.dictionaries import get_dictionary
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token,
raise_on_unexpected_status=True
)
call_result = await get_dictionary.asyncio(
'status_codes.csv',
client=dqops_client
)
update_dictionary
Updates an existing data dictionary CSV file, replacing the dictionary's file content.
Follow the link to see the source code on GitHub.
PUT
Parameters of this method are described below
Property name | Description | Data type | Required |
---|---|---|---|
dictionary_name |
Data dictionary file name that will be updated | string |
Request body
Description | Data type | Required |
---|---|---|
Data dictionary model | DataDictionaryModel |
Usage examples
Execution
Execution
from dqops import client
from dqops.client.api.dictionaries import update_dictionary
from dqops.client.models import DataDictionaryModel
dqops_client = client.Client(
'http://localhost:8888/'
)
request_body = DataDictionaryModel(
dictionary_name='sample_dictionary',
file_content='USD
EUR
GBP
AUD
CHF
'
)
call_result = update_dictionary.sync(
'status_codes.csv',
client=dqops_client,
json_body=request_body
)
Execution
from dqops import client
from dqops.client.api.dictionaries import update_dictionary
from dqops.client.models import DataDictionaryModel
dqops_client = client.Client(
'http://localhost:8888/'
)
request_body = DataDictionaryModel(
dictionary_name='sample_dictionary',
file_content='USD
EUR
GBP
AUD
CHF
'
)
call_result = await update_dictionary.asyncio(
'status_codes.csv',
client=dqops_client,
json_body=request_body
)
Execution
from dqops import client
from dqops.client.api.dictionaries import update_dictionary
from dqops.client.models import DataDictionaryModel
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token
)
request_body = DataDictionaryModel(
dictionary_name='sample_dictionary',
file_content='USD
EUR
GBP
AUD
CHF
'
)
call_result = update_dictionary.sync(
'status_codes.csv',
client=dqops_client,
json_body=request_body
)
Execution
from dqops import client
from dqops.client.api.dictionaries import update_dictionary
from dqops.client.models import DataDictionaryModel
token = 's4mp13_4u7h_70k3n'
dqops_client = client.AuthenticatedClient(
'http://localhost:8888/',
token=token
)
request_body = DataDictionaryModel(
dictionary_name='sample_dictionary',
file_content='USD
EUR
GBP
AUD
CHF
'
)
call_result = await update_dictionary.asyncio(
'status_codes.csv',
client=dqops_client,
json_body=request_body
)