Below we describe the low level API to the Quantum Inspire platform. Quantum Inspire also offers a Software Development Kit (SDK) to advanced users that will allow programatic control over all functionality using Python. For more information see the Software Development Kit page.
Application Programmer Interface (API)
Warning: the interface defined by this alpha-release may change in the future.
Forms are provided at the bottom of most pages to create new objects or modify existing objects.
To give you an idea of the relation between the objects in the API, please refer to this (preliminary) UML class diagram:
import coreapi auth = coreapi.auth.BasicAuthentication(username='username', password='password') # Initialize a client & load the schema document client = coreapi.Client(auth=auth) schema = client.get("https://dev.quantum-inspire.com/api/schema") # Interact with the API endpoint action = ["projects", "list"] result = client.action(schema, action) print(result)
import requests from requests.auth import HTTPBasicAuth server = r'https://dev.quantum-inspire.com/api' username='username' auth = HTTPBasicAuth(username, passwd) result=requests.get(server+'/projects', auth=auth) print('result status: %d' % result.status_code) print(result.json())