Skip to content

Commit

Permalink
Update request payload to API v0.3 (#118)
Browse files Browse the repository at this point in the history
* update request payload to v0.3

* return name field
  • Loading branch information
splch committed Apr 17, 2023
1 parent 5d7042a commit 40a2a34
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions qiskit_ionq/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -379,11 +379,11 @@ def qiskit_to_ionq(circuit, backend, passed_args=None):

target = backend.name()[5:]
ionq_json = {
"lang": "json",
"target": target,
"shots": passed_args.get("shots"),
"name": circuit.name,
"body": {
"input": {
"format": "ionq.circuit.v0",
"gateset": backend.gateset(),
"qubits": circuit.num_qubits,
"circuit": ionq_circ,
Expand Down
8 changes: 4 additions & 4 deletions test/helpers/test_qiskit_to_ionq.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,15 +175,15 @@ def test_full_circuit(simulator_backend):
expected_output_map = [1, 0]
expected_metadata = {"shots": "200", "sampler_seed": "42"}
expected_rest_of_payload = {
"lang": "json",
"target": "simulator",
"shots": 200,
"name": "test_name",
"noise": {
"model": "ideal",
"seed": None,
},
"body": {
"input": {
"format": "ionq.circuit.v0",
"gateset": "qis",
"qubits": 2,
"circuit": [
Expand Down Expand Up @@ -317,15 +317,15 @@ def test_full_native_circuit(simulator_backend):
}
expected_metadata = {"shots": "200", "sampler_seed": "23"}
expected_rest_of_payload = {
"lang": "json",
"target": "simulator",
"name": "blame_test",
"shots": 200,
"noise": {
"model": "harmony",
"seed": None,
},
"body": {
"input": {
"format": "ionq.circuit.v0",
"gateset": "native",
"qubits": 3,
"circuit": [
Expand Down

0 comments on commit 40a2a34

Please sign in to comment.