# import\_project\_from\_json

<pre class="language-python"><code class="lang-python">dbnl.import_project_from_json(
    *,
    params: dict[str, Any],
) -> <a data-footnote-ref href="#user-content-fn-1">Project</a>:
</code></pre>

## Parameters

<table><thead><tr><th width="173">Arguments</th><th>Description</th></tr></thead><tbody><tr><td><code>params</code></td><td><p>JSON object representing the Project, generally based on a <a href="/pages/vfXFauh5ZnUjluqFCP7i">Project</a> exported via <a href="/pages/0zhWpsAwiqmRPyrltkxX">export_project_as_json</a>. Example:</p><p></p><pre class="language-json"><code class="lang-json"><strong>{
</strong><strong>    "project": {
</strong><strong>        "name": "My Project",
</strong><strong>        "description": "This is my project."
</strong><strong>    },
</strong><strong>    "tags": [
</strong><strong>        {
</strong><strong>            "name": "my-tag",
</strong><strong>            "description" :"This is my tag."
</strong><strong>        }
</strong><strong>    ],
</strong><strong>    "test_specs": [
</strong><strong>        {
</strong>            "assertion": { "name": "less_than", "params": { "other": 0.5 } },
            "description": "Testing the difference in the example statistic",
            "name": "Gr.0: Non Parametric Difference: Example_Statistic",
            "statistic_inputs": [
                {
                    "select_query_template": {
                        "filter": null,
                        "select": "{EXPERIMENT}.Example_Statistic"
                    }
                },
                {
                    "select_query_template": {
                        "filter": null,
                        "select": "{BASELINE}.Example_Statistic"
                    }
                }
            ],
            "statistic_name": "my_stat",
            "statistic_params": {},
            "tag_names": ["my-tag"]
<strong>        }
</strong><strong>    ]
</strong><strong>}
</strong></code></pre></td></tr></tbody></table>

## Returns

<table><thead><tr><th width="167">Type</th><th>Description</th></tr></thead><tbody><tr><td><a href="/pages/vfXFauh5ZnUjluqFCP7i">Project</a></td><td>The newly created dbnl Project.</td></tr></tbody></table>

## Examples

```python
import dbnl
dbnl.login()


proj1 = dbnl.get_or_create_project(name="test_proj1")
export_json = dbnl.export_project_as_json(project=proj1)
export_json["project"]["name"] = "test_proj2"
proj2 = dbnl.import_project_from_json(params=export_json)

assert proj2.name == "test_proj2"
```

[^1]: [Project](/v0.20.x/using-distributional/python-sdk/sdk-objects/project.md)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.dbnl.com/v0.20.x/using-distributional/python-sdk/sdk-functions/project/import_project_from_json.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
