Skip to main content

GraphDB Python

Project description

GraphDB Python API

No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)

This Python package is automatically generated by the Swagger Codegen project:

  • API version: 2.0
  • Package version: 1.0.0
  • Build package: io.swagger.codegen.languages.PythonClientCodegen

Requirements.

Python 2.7 and 3.4+

Installation & Usage

pip install

pip install graphdb-python

(or sudo python setup.py install to install the package for all users)

Then import the package:

import graphdb

Getting Started

Please follow the installation procedure and then run the following:

RDF4J API

from __future__ import print_function
import time
from graphdb import rdf4j
from graphdb.rdf4j.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rdf4j.ContextsApi(rdf4j.ApiClient(configuration))
repository_id = 'repository_id_example' # str | The repository ID

try:
    # Gets a list of resources that are used as context identifiers.
    api_response = api_instance.get_repository_contexts(repository_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ContextsApi->get_repository_contexts: %s\n" % e)

GraphDB Workbench API

from __future__ import print_function
import time
import graphdb.graphdb_workbench
from graphdb.graphdb_workbench.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = graphdb.graphdb_workbench.ClusterManagementControllerApi(swagger_client.ApiClient(configuration))
bean = graphdb.graphdb_workbench.WorkerCloneBean() # WorkerCloneBean | bean

try:
    # Clone a worker
    api_response = api_instance.clone_worker_using_post(bean)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ClusterManagementControllerApi->clone_worker_using_post: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://localhost

RDF4J

Class Method HTTP request Description
ContextsApi get_repository_contexts GET /repositories/{repositoryID}/contexts Gets a list of resources that are used as context identifiers.
GraphStoreApi add_statements_to_indirect_namedgraph POST /repositories/{repositoryID}/rdf-graphs/service Add statements to an INDIRECTLY referenced named graph
GraphStoreApi add_statements_to_namedgraph POST /repositories/{repositoryID}/rdf-graphs/{graph} Add statements to a DIRECTLY referenced named graph
GraphStoreApi delete_statements_from_indirect_namedgraph DELETE /repositories/{repositoryID}/rdf-graphs/service Clear an INDIRECTLY referenced named graph
GraphStoreApi delete_statements_from_namedgraph DELETE /repositories/{repositoryID}/rdf-graphs/{graph} Clear a DIRECTLY referenced named graph
GraphStoreApi get_all_statements_from_indirect_namedgraph GET /repositories/{repositoryID}/rdf-graphs/service Fetch all statements from an INDIRECTLY referenced named graph
GraphStoreApi get_all_statements_from_namedgraph GET /repositories/{repositoryID}/rdf-graphs/{graph} Fetch all statements from a DIRECTLY referenced named graph
NamespacesApi delete_namespace_for_prefix DELETE /repositories/{repositoryID}/namespaces/{namespacesPrefix} Remove namespace for a particular prefix
NamespacesApi get_namespace_for_prefix GET /repositories/{repositoryID}/namespaces/{namespacesPrefix} Get namespace for a particular prefix
NamespacesApi set_namespace_for_prefix PUT /repositories/{repositoryID}/namespaces/{namespacesPrefix} Set namespace for a particular prefix
ProtocolApi get_protocol_version GET /protocol Fetch the protocol version
RepositoriesApi delete_repository DELETE /repositories/{repositoryID} Repository removal
RepositoriesApi delete_statements DELETE /repositories/{repositoryID}/statements Deletes statements from the repository.
RepositoriesApi get_all_repositories GET /repositories An overview of the repositories that are available on a server.
RepositoriesApi get_all_statements GET /repositories/{repositoryID}/statements Fetches statements from the repository.
RepositoriesApi get_repository_size GET /repositories/{repositoryID}/size The repository size (defined as the number of statements it contains)
RepositoriesApi put_statements PUT /repositories/{repositoryID}/statements Updates data in the repository, replacing any existing data with the supplied data
SparqlApi execute_get_select_query GET /repositories/{repositoryID} Send queries on a specific repository with ID. This resource represents a SPARQL query endpoint
SparqlApi update POST /repositories/{repositoryID}/statements Performs updates on the data in the repository
TransactionsApi execute_transaction_action PUT /repositories/{repositoryID}/transactions/{transactionID} Execute a transaction action
TransactionsApi rollback_transaction DELETE /repositories/{repositoryID}/transactions/{transactionID} Abort a transaction
TransactionsApi start_new_transaction POST /repositories/{repositoryID}/transactions Start a new transaction

GraphDB Workbench

Class Method HTTP request Description
ClusterManagementControllerApi clone_worker_using_post POST /rest/cluster/nodes/clone Clone a worker
ClusterManagementControllerApi connect_masters_using_post POST /rest/cluster/masters/{masterRepositoryId}/peers Connect two masters
ClusterManagementControllerApi connect_worker_using_post POST /rest/cluster/masters/{masterRepositoryId}/workers Connect a worker to a master
ClusterManagementControllerApi disconnect_masters_using_delete DELETE /rest/cluster/masters/{masterRepositoryId}/peers Disconnect two masters
ClusterManagementControllerApi disconnect_worker_using_delete DELETE /rest/cluster/masters/{masterRepositoryId}/workers Disconnect a worker from a master
ClusterManagementControllerApi do_backup_using_get GET /rest/cluster/masters/{masterRepositoryId}/backup Initiate a cluster backup
ClusterManagementControllerApi do_restore_using_get GET /rest/cluster/masters/{masterRepositoryId}/restore Initiate a cluster restore
ClusterManagementControllerApi get_master_using_get GET /rest/cluster/masters/{masterRepositoryId} Get information about a master
ClusterManagementControllerApi get_workers_for_master_using_get GET /rest/cluster/masters/{masterRepositoryId}/workers Get workers connected to a master
ClusterManagementControllerApi set_master_using_post POST /rest/cluster/masters/{masterRepositoryId} Set master attribute
ImportControllerApi import_server_file_using_post POST /rest/data/import/server/{repositoryID} Import a server file into the repository
ImportControllerApi import_url_upload_using_post POST /rest/data/import/upload/{repositoryID}/url Import from data URL into the repository
ImportControllerApi interrupt_server_import_using_delete DELETE /rest/data/import/server/{repositoryID} Cancel server file import operation
ImportControllerApi list_server_files_using_get GET /rest/data/import/server/{repositoryID} Get server files available for import
LocationManagementControllerApi activate_location_using_post POST /rest/locations/activate Activate a connected GraphDB location
LocationManagementControllerApi add_location_using_post POST /rest/locations Connect to a remote GraphDB location
LocationManagementControllerApi change_location_using_put PUT /rest/locations Modify settings for a connected GraphDB location
LocationManagementControllerApi delete_location_using_delete DELETE /rest/locations Disconnect a GraphDB location
LocationManagementControllerApi get_active_location_using_get GET /rest/locations/active Get active connected GraphDB location
LocationManagementControllerApi get_all_using_get GET /rest/locations Get all connected GraphDB locations
LocationManagementControllerApi set_default_repository_using_post POST /rest/locations/active/default-repository Set default repository for active GraphDB location
RepositoryManagementControllerApi create_repository_using_post POST /rest/repositories Create a repository in an attached Sesame location (ttl file)
RepositoryManagementControllerApi delete_repository_using_delete DELETE /rest/repositories/{repositoryID} Delete a repository in an attached Sesame location
RepositoryManagementControllerApi download_repository_config_turtle_using_get GET /rest/repositories/{repositoryID}/download Download repository configuration as a Turtle file
RepositoryManagementControllerApi download_repository_config_zip_using_get GET /rest/repositories/{repositoryID}/downloadZip Download repository configuration as a zip file
RepositoryManagementControllerApi edit_repository_using_put PUT /rest/repositories/{repositoryID} Edit repository configuration
RepositoryManagementControllerApi get_default_config_using_get GET /rest/repositories/defaultConfig/{repositoryType} Get the default repository configuration for the repository type
RepositoryManagementControllerApi get_repositories_using_get GET /rest/repositories Get all repositories in the active location or another location
RepositoryManagementControllerApi get_repository_config_json_using_get GET /rest/repositories/{repositoryID} Get repository configuration as JSON
RepositoryManagementControllerApi repository_size_using_get GET /rest/repositories/{repositoryID}/size Get repository size
RepositoryManagementControllerApi restart_repository_using_post POST /rest/repositories/{repositoryID}/restart Restart a repository
SavedQueriesControllerApi create_query_using_post POST /rest/sparql/saved-queries Create a new saved query
SavedQueriesControllerApi delete_sample_query_using_delete DELETE /rest/sparql/saved-queries Delete an existing saved query
SavedQueriesControllerApi edit_sample_query_using_put PUT /rest/sparql/saved-queries Edit an existing saved query
SavedQueriesControllerApi get_queries_using_get GET /rest/sparql/saved-queries Get all saved queries visible for the user or single saved query by name and owner.
SecurityManagementControllerApi change_user_settings_using_patch PATCH /rest/security/user/** Change settings for a user
SecurityManagementControllerApi create_user_using_post POST /rest/security/user/** Create a user
SecurityManagementControllerApi delete_user_using_delete DELETE /rest/security/user/** Delete a user
SecurityManagementControllerApi edit_user_using_put PUT /rest/security/user/** Edit a user
SecurityManagementControllerApi get_all_users_using_get GET /rest/security/user Get all users
SecurityManagementControllerApi get_user_using_get GET /rest/security/user/** Get a user
SecurityManagementControllerApi is_enabled_free_access_using_get GET /rest/security/freeaccess Check if free access is enabled
SecurityManagementControllerApi is_enabled_security_using_get GET /rest/security Check if security is enabled
SecurityManagementControllerApi set_enable_free_access_using_post POST /rest/security/freeaccess Enable or disable free access
SecurityManagementControllerApi set_enable_security_using_post POST /rest/security Enable or disable security
SparqlTemplateControllerApi create_sparql_template_using_post POST /rest/sparql-template/create Create a new SPARQL template
SparqlTemplateControllerApi delete_sparql_template_using_delete DELETE /rest/sparql-template/delete Delete an existing SPARQL template
SparqlTemplateControllerApi get_sparql_template_content_using_get GET /rest/sparql-template/configuration Get a SPARQL template configuration
SparqlTemplateControllerApi get_sparql_template_i_ds_using_get GET /rest/sparql-template Get IDs of all configured SPARQL templates per current active repository
SparqlTemplateControllerApi update_sparql_template_using_put PUT /rest/sparql-template/edit Edit an existing SPARQL template
SqlViewsControllerApi create_sql_view_using_post POST /rest/sql-views/tables Create a new SQL view
SqlViewsControllerApi delete_sql_view_using_delete DELETE /rest/sql-views/tables/{name} Delete an existing saved query
SqlViewsControllerApi get_sql_view_names_using_get GET /rest/sql-views/tables Get all SQL view names for current repository.
SqlViewsControllerApi get_sql_view_using_get GET /rest/sql-views/tables/{name} Get a SQL view configuration.
SqlViewsControllerApi update_sql_view_using_put PUT /rest/sql-views/tables/{name} Edit an existing SQL view
StatelessLoginControllerApi login_using_post POST /rest/login/** Authenticate user with a password

Documentation For Models

Documentation For Authorization

All endpoints do not require authorization.

Author

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

GraphDB Python-0.0.6.tar.gz (61.6 kB view details)

Uploaded Source

Built Distribution

GraphDB_Python-0.0.6-py3-none-any.whl (108.8 kB view details)

Uploaded Python 3

File details

Details for the file GraphDB Python-0.0.6.tar.gz.

File metadata

  • Download URL: GraphDB Python-0.0.6.tar.gz
  • Upload date:
  • Size: 61.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for GraphDB Python-0.0.6.tar.gz
Algorithm Hash digest
SHA256 0493ca6d493afc8b197fe5893de4698cf613cda47090f365d013d2aa360036af
MD5 b3bbbb0408f6f90d31925b137ee8b837
BLAKE2b-256 1fe277a0c04e7f89b41ae3ac6e57345a222b86f70f8e0a08cb8dc7069798f507

See more details on using hashes here.

File details

Details for the file GraphDB_Python-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: GraphDB_Python-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 108.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for GraphDB_Python-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 8dcd1015083aec5eaf6b282bbdb119c46beac31a9b58ba7695ce19db5bb75f38
MD5 6414e2bd1256d078b95f8beffb5db82e
BLAKE2b-256 33d2da6ff802df40179111fb110100f7b564829d10daf4f778b799805ad8d97c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page