Metadata-Version: 2.1
Name: benchlingapi
Version: 2.0.0
Summary: An unofficial python wrapper for the Benchling API
Home-page: https://www.github.com/klavinslab/benchling-api
Author: Justin Vrana
Author-email: justin.vrana@gmail.com
Requires-Python: >=3.7,<4.0
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Science/Research
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.7
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
Requires-Dist: bs4 (>=0.0.1,<0.0.2)
Requires-Dist: inflection (>=0.3.1,<0.4.0)
Requires-Dist: marshmallow (==3.0.0rc1)
Requires-Dist: requests (>=2.22,<3.0)
Requires-Dist: urlopen (>=1.0,<2.0)
Project-URL: Documentation, http://klavinslab.org/benchling-api/
Project-URL: Repository, https://pypi.org/project/benchlingapi/
Description-Content-Type: text/markdown

# BenchlingAPI

The (unofficial) python API wrapper for Benchling.

## Installation

```
pip install benchlingapi -U
```

## Getting Started

`api = Session("your_secret_benchling_api_key")`

`api.DNASequence()`

`api.AASequence()`

`api.CustomEntity()`

`api.Oligo()`

`api.Registry.one()`

`api.DNASequence.one()`

`api.DNASequence.last(50)`

`api.Folder.find_by_name("MyFolderName")`

```
dna.set_schema("My DNA Schema")
dna.register()
```

## Testing

Testing is done using `pytest`. Tests will create live requests to a Benchling account.
Since testing is done live, a Benchling account will need to be setup along with testing
data.

To run tests, you must have a Benchling Account with an API key. Tests require a file in
'tests/secrets/config.json' with the following format:

```
{
  "credentials": {
    "api_key": "asdahhjwrthsdfgadfadfgadadsfa"
  },
  "sharelinks": [
    "https://benchling.com/s/seq-asdfadsfaee"
  ],
  "project": {
    "name": "API"
  },
  "trash_folder": {
    "name": "API_Trash"
  },
  "inventory_folder": {
    "name": "API_Inventory"
  }
}
```

On the Benchling side of things, in the account liked to the `credentials["api_key"]`, you must
have a project corresponding to the `project["name"]` value above. Within this project, you should
have two folder corresponding to the `trash_folder` and `inventory_folder` values above. Additionally,
you should have at least one example of an AminoAcid, DNASequence, CustomEntity, and Oligo stored within
your `inventory_folder`. Tests will copy the examples from the `inventory_folder` for downstream tests.
After the tests, conclude, inventory in the `trash_folder` will get archived.

#### Happy Cloning!
