qiskit-documentation/docs/api/qiskit/1.2/qiskit.providers.models.Bac...

65 lines
2.9 KiB
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
title: BackendStatus (v1.2)
description: API reference for qiskit.providers.models.BackendStatus in qiskit v1.2
in_page_toc_min_heading_level: 1
python_api_type: class
python_api_name: qiskit.providers.models.BackendStatus
---
# BackendStatus
<Class id="qiskit.providers.models.BackendStatus" isDedicatedPage={true} github="https://github.com/Qiskit/qiskit/tree/stable/1.2/qiskit/providers/models/backendstatus.py#L19-L94" signature="qiskit.providers.models.BackendStatus(backend_name, backend_version, operational, pending_jobs, status_msg)" modifiers="class">
Bases: [`object`](https://docs.python.org/3/library/functions.html#object "(in Python v3.13)")
Class representing Backend Status.
Initialize a BackendStatus object
**Parameters**
* **backend\_name** ([*str*](https://docs.python.org/3/library/stdtypes.html#str "(in Python v3.13)")) The backends name
* **backend\_version** ([*str*](https://docs.python.org/3/library/stdtypes.html#str "(in Python v3.13)")) The backends version of the form X.Y.Z
* **operational** ([*bool*](https://docs.python.org/3/library/functions.html#bool "(in Python v3.13)")) True if the backend is operational
* **pending\_jobs** ([*int*](https://docs.python.org/3/library/functions.html#int "(in Python v3.13)")) The number of pending jobs on the backend
* **status\_msg** ([*str*](https://docs.python.org/3/library/stdtypes.html#str "(in Python v3.13)")) The status msg for the backend
**Raises**
[**QiskitError**](exceptions#qiskit.exceptions.QiskitError "qiskit.exceptions.QiskitError") If the backend version is in an invalid format
## Methods
### from\_dict
<Function id="qiskit.providers.models.BackendStatus.from_dict" github="https://github.com/Qiskit/qiskit/tree/stable/1.2/qiskit/providers/models/backendstatus.py#L50-L62" signature="from_dict(data)" modifiers="classmethod">
Create a new BackendStatus object from a dictionary.
**Parameters**
**data** ([*dict*](https://docs.python.org/3/library/stdtypes.html#dict "(in Python v3.13)")) A dictionary representing the BaseBakend to create. It will be in the same format as output by [`to_dict()`](#qiskit.providers.models.BackendStatus.to_dict "qiskit.providers.models.BackendStatus.to_dict").
**Returns**
The BackendStatus from the input dictionary.
**Return type**
[BackendStatus](#qiskit.providers.models.BackendStatus "qiskit.providers.models.BackendStatus")
</Function>
### to\_dict
<Function id="qiskit.providers.models.BackendStatus.to_dict" github="https://github.com/Qiskit/qiskit/tree/stable/1.2/qiskit/providers/models/backendstatus.py#L64-L70" signature="to_dict()">
Return a dictionary format representation of the BackendStatus.
**Returns**
The dictionary form of the QobjHeader.
**Return type**
[dict](https://docs.python.org/3/library/stdtypes.html#dict "(in Python v3.13)")
</Function>
</Class>