The current, latest version of the Molport API is v3.0. To prevent broken experiences for people, we strongly recommend to upgrade your application to the latest API version. Please, visit Molport API History of Changes for the latest changes in API interfaces and/or data structures.
Molport API is implemented as REST interfaces. REST stands for Representational State Transfer. It relies on a stateless, client-server, cacheable communications. JSON (JavaScript Object Notation) is used as a lightweight data-interchange format.
Molport JSON request generic form is specific for API interface. Please, check the API Documentation to see the data structures that are used.
Molport JSON response generic form:
{ "Result": { "Status": 1|2, "Message":}, "Data": { "Version": , … [Data Object] … } }
where:
Status - int; possible values:
1 - operation was successful,
2 - operation was not successful;
Message - string; short informative, human readable message;
Version - string; version number of returned Molport JSON data objects;
Data Object - json; JSON representation of returned data objects.
If the source data contains special characters, these characters are escaped. List of escaped special characters can be seen below.
Special Character | Escaped Output |
---|---|
Quotation mark (") | \" |
Backslash (\) | \\ |
Slash (/) | \/ |
Backspace | \b |
Form feed | \f |
New line | \n |
Carriage return | \r |
Horizontal tab | \t |
Description: Method to load information about molecule from database if Molport compound ID is known.
Request:
METHOD | GET |
URL |
Using username and password:
api.molport.com/api/molecule/load?molecule={molecule id}&username={username}&authenticationcode={authentication code}
Using API key:
api.molport.com/api/molecule/load?molecule={molecule id}&apikey={API key}
Supported protocols: http, https |
Response:
DATA TYPE | JSON |
JSON |
Id - int; molecule identifier in Molport database; |
Example:
URL |
Using username and password: |
REQUEST |
Molport compound ID 2325020 or Molport-002-325-020 in URL |
RESPONSE |
{ "Result": { "Status": 1, "Message": "Molecule found!" }, "Data": { "Molecule": { "Id": 2325020, "Molport Id": "Molport-002-325-020", "SMILES": "CCOC(O)c1[nH]c2ccc(C)cc2c1NC(O)CC", "IUPAC": "ethyl 5-methyl-3-propanamido-1H-indole-2-carboxylate", "Formula": "C15H18N2O3", "Molecular Weight": 274.32, "Status": "shop", "Type": "stock", "Largest Stock": "124", "Largest Stock Measure": "mg", "Largest Stock Measure Id": 234, "Catalogues": { "Screening Block Suppliers": [ { "Supplier Name": "Specs", "Supplier Id": 2070, "Minimum Order": 200, "Currency": "USD", "Currency Id": 2, "Catalogues": [ { "Catalog Id": 84777984, "Catalog Number": "AG-690/10530016", "Stock": 2, "Stock Measure": "mg", "Stock Measure Id": 234, "Last Update Date": "today", "Available Packings": [ { "Amount": 2, "Measure": "mg", "Measure Id": 234, "Price": 32.20, "Currency": "USD", "Currency Id": 2, "Delivery Days": 7 } ] } ], "Shipment Costs": [ { "Price": 50, "Currency": "USD", "Currency Id": 2, "Location Type": "REGION", "Location": "EUROPE", "Location Id": 1, "Shipment Type": "Basic Shipping", "Shipment Type Id": 3 }, { "Price": 50, "Currency": "USD", "Currency Id": 2, "Location Type": "REGION", "Location": "USA", "Location Id": 2, "Shipment Type": "Basic Shipping", "Shipment Type Id": 3 }, { "Price": 50, "Currency": "USD", "Currency Id": 2, "Location Type": "REGION", "Location": "CANADA AND MEXICO", "Location Id": 3, "Shipment Type": "Basic Shipping", "Shipment Type Id": 3 }, { "Price": 50, "Currency": "USD", "Currency Id": 2, "Location Type": "REGION", "Location": "OTHER LOCATIONS", "Location Id": 4, "Shipment Type": "Basic Shipping", "Shipment Type Id": 3 } ], "Country Name": "Netherlands", "Country ISO Code": "NL", "Shipping Country Name": "Netherlands", "Shipping Country ISO Code": "NL" }, ], }, "Synonyms": [ "ethyl", "ethyl 5-methyl-3-(propanoylamino)-1H-indole-2-carboxylate" ], }, "Version": "v.3.0.2" } } |
Description: Method to search molecules with chemical search if SMILES is known.
Currently supported chemical search types are:
Request:
METHOD | POST |
URL |
api.molport.com/api/chemical-search/search |
JSON |
API Key - string; API key provided by Molport to institutional organizations; |
Response:
DATA TYPE | JSON |
JSON |
Id - int; molecule identifier in Molport database; |
Example:
URL |
api.molport.com/api/chemical-search/search |
REQUEST |
Using username and password:
{ "User Name":"john.spade", "Authentication Code":"fasdga34a3", "Structure":"CC(C)(C)OC(=O)N1CCCCCC1C(O)=O", "Search Type":4, "Maximum Search Time":60000, "Maximum Result Count":10000, "Chemical Similarity Index":0.9 } Using API key: { "API Key":"880d8343-8ui2-418c-9g7a-68b4e2e78c8b", "Structure":"CC(C)(C)OC(=O)N1CCCCCC1C(O)=O", "Search Type":4, "Maximum Search Time":60000, "Maximum Result Count":10000, "Chemical Similarity Index":0.9 } |
RESPONSE |
{ "Result": { "Status": 2, "Message": "Size: 2" }, "Data": { "Molecules": [ { "Id": 28065133, "Molport Id": "Molport-028-065-133", "SMILES": "CC(NC(O)COc1ccc(cc1)C(C)O)c1cccs1", "Canonical SMILES": "CC(=O)C1=CC=C(C=C1)OCC(=O)C2=CN(CCC#N)C3=CC=CC=C23", "Verified Amount": 0, "Unverified Amount": 10000, "Similarity Index": 0.0 } ], "Version": "v.3.0.2" } } |
Description: Return all orders for the specific client ordered by order date descending.
Request:
API VERSION | 1.0.0 |
METHOD | GET |
URL |
api.molport.com/api/orders |
HTTP HEADERS |
MOLPORT-API-ID - string; predefined value Order-Tracking |
Response:
DATA TYPE | JSON, array of objects |
JSON |
200 (OK) - the request was successful
[ 401 (Unauthorized) - authentication failed or user doesn't have permissions for requested operation 403 (Forbidden) - access denied, header values not provided |
Description: Return 1 specific order.
Request:
API VERSION | 1.0.0 |
METHOD | GET |
URL |
api.molport.com/api/order/[order key] |
HTTP HEADERS |
MOLPORT-API-ID - string; predefined value Order-Tracking |
Response:
DATA TYPE | JSON, array of objects |
JSON |
200 (OK) - the request was successful and orders were extracted
{ 401 (Unauthorized) - authentication failed or user doesn't have permissions for requested operation 403 (Forbidden) - access denied, header values not provided |
You can make up to 3 chemical search queries simultaneously. After exceeding this limit, an error announcement
will appear that will limit your search traffic.
You can also make 3 active molecule catalog search queries to retrieve information from our database in parallel
to chemical search queries. Similarly the same error announcement will appear when exceeding this limit.
Each users API account is limited to 10000 requests per month, meaning each user can submit up to 10000 requests
each month. The remaining request count is refreshed at the start of each month. If you require more requests
per month you can contact sales@molport.com to request an increased
monthly cap.
How to run the CURL sample
Example below describes how to run the CURL sample. Please, perform the following steps:
How to run the JavaScript sample
Example below describes how to run the CURL sample. Please, perform the following steps:
Source
Provided example uses AJAX (JSONP) to overcome cross-domain limitations. jQuery library is used to execute AJAX requests. Current example can be used reused without any limitations.
Limitations
Please, contact Molport to aquire username and password/authentification code.
How to run the Java sample
Example below describes how to run the Molport Java API demo project on Microsoft Windows platform. With minor modifications, it can be run on NIX platforms (Linux, AIX, etc.) too. To use the jar and run the application, perform the following steps:
To execute chemical search:
Sample for CC(C)(C)OC(=O)N1CCCCCC1C(O)=O exact fragment search:
To load information about molecule:
Sample for molecule Molport-002-463-875:
Build from Java source
Limitations
Please, contact Molport to aquire username and password/authentification code.
How to run the C# sample
Example below describes how to run the Molport C# API demo project on Microsoft Windows platform. To use the exe, perform the following steps:
To execute chemical search:
Sample for CC(C)(C)OC(=O)N1CCCCCC1C(O)=O exact fragment search:
To load information about molecule:
Sample for molecule Molport-002-463-875:
Build from C# source
Limitations
Please, contact Molport to aquire username and password/authentification code.
How to run the Python sample
Example below describes how to run the Molport Python API demo sample on Microsoft Windows
platform. To run te script, perform the following steps:
Limitations
Please, contact Molport to aquire username and password/authentification code.