---
title: QasmQobjExperiment (v1.4)
description: API reference for qiskit.qobj.QasmQobjExperiment in qiskit v1.4
source: https://eu-de.quantum.cloud.ibm.com/docs/en/api/qiskit/1.4/qiskit.qobj.QasmQobjExperiment
---

# QasmQobjExperiment

*class* `qiskit.qobj.QasmQobjExperiment(config=None, header=None, instructions=None)`

[GitHub](https://github.com/Qiskit/qiskit/tree/stable/1.4/qiskit/qobj/qasm_qobj.py#L205-L290)

Bases: [`object`](https://docs.python.org/3/library/functions.html#object)

An OpenQASM 2 Qobj Experiment.

Each instance of this class is used to represent an OpenQASM 2 experiment as part of a larger OpenQASM 2 qobj.

Instantiate a QasmQobjExperiment.

> **Deprecated since version 1.2**
>
> The class `qiskit.qobj.qasm_qobj.QasmQobjExperiment` is deprecated as of qiskit 1.2. It will be removed in the 2.0 release. The Qobj class and related functionality are part of the deprecated BackendV1 workflow, and no longer necessary for BackendV2. If a user workflow requires Qobj it likely relies on deprecated functionality and should be updated to use BackendV2.

**Parameters**

- **config** ([*QasmQobjExperimentConfig*](/docs/api/qiskit/1.4/qiskit.qobj.QasmQobjExperimentConfig "qiskit.qobj.QasmQobjExperimentConfig")) – A config object for the experiment
- **header** (*QasmQobjExperimentHeader*) – A header object for the experiment
- **instructions** ([*list*](https://docs.python.org/3/library/stdtypes.html#list)) – A list of [`QasmQobjInstruction`](/docs/api/qiskit/1.4/qiskit.qobj.QasmQobjInstruction "qiskit.qobj.QasmQobjInstruction") objects

## Methods

### from\_dict

*classmethod* `from_dict(data)`

[GitHub](https://github.com/Qiskit/qiskit/tree/stable/1.4/qiskit/qobj/qasm_qobj.py#L263-L284)

Create a new QasmQobjExperiment object from a dictionary.

**Parameters**

**data** ([*dict*](https://docs.python.org/3/library/stdtypes.html#dict)) – A dictionary for the experiment config

**Returns**

The object from the input dictionary.

**Return type**

[QasmQobjExperiment](#qiskit.qobj.QasmQobjExperiment "qiskit.qobj.QasmQobjExperiment")

### to\_dict

`to_dict()`

[GitHub](https://github.com/Qiskit/qiskit/tree/stable/1.4/qiskit/qobj/qasm_qobj.py#L250-L261)

Return a dictionary format representation of the Experiment.

**Returns**

The dictionary form of the QasmQObjExperiment.

**Return type**

[dict](https://docs.python.org/3/library/stdtypes.html#dict)
