Instructions for Web Service

The OPSIN web interface can be utilised in three ways:


Simply enter a chemical name into the web form and chemical representations will be returned

By requesting a particular output using file extensions:

The web service resides at . A request to that URL concatenated with the URL encoded chemical name will give a structure where the representation chosen is decided by the extension:

  • .cml gives CML with 2d coordinates
  • .no2d.cml gives CML without 2d coordinates
  • .inchi gives InChI
  • .stdinchikey gives StdInChIKey
  • .png gives a depiction
  • .smi gives SMILES

For example yields a depiction of cyclopropane.

By content negotiation:

The web service is RESTful and will respond appropriately to requests with the appropriate MIME type. For your convenience the MIME types expected are:

  • chemical/x-cml for CML with 2d coordinates
  • chemical/x-no2d-cml for CML without 2d coordinates
  • chemical/x-inchi for InChI
  • chemical/x-stdinchikey for StdInChIKey
  • image/png for png depiction
  • chemical/x-daylight-smiles for SMILES

The web service resides at

Specification of non ASCII characters:

Greek Characters

Greek characters may be specified by:

  • The appropriate UTF-8 character e.g. λ
  • The romanised name for the letter e.g. lambda
  • The romanised name for the letter surrounded by dots e.g. .lambda.
  • The corresponding modern letter prefixed with a dollar e.g. $l

Super scripts

Super scripts may be specified by:

  • A carat with bracketing e.g. N^(2)
  • A carat e.g. N^2
  • Bracketing e.g. N(2)
  • Using tildes e.g. N~2~

Note that for locants OPSIN will be able to disambiguate that N2 means N^2 and for von Baeyer systems OPSIN will intelligently guess what should have been superscripted. For spiro systems indication of superscripts is required.