Page tree
Skip to end of metadata
Go to start of metadata

Introduction

ChemAxon provides a public Maven repository at https://hub.chemaxon.com for integrating our products and modules. It is designed for integrators and resellers, but is available for any registered ChemAxon user.

In order to use this repository, you should follow these two steps:

  • Register a ChemAxon Pass account, unless you already have one. (The email associated with the Pass registration will serve as the username credential.)
  • Use the ChemAxon Pass account to log in to https://hub.chemaxon.com and generate an API key. (This API key will serve as the password credential.)

These steps are described in detail in the followings.

How to Register a ChemAxon Account

If you have already registered on www.chemaxon.com, then you are done. Otherwise, you should follow these steps to register:

  1. Go to https://pass.chemaxon.com/sign-up, which is also available from ChemAxon site.


  2. On the Pass registration form, enter your details. The specified email address will serve as the username credential to access the Maven repository.



  3. After that, an email is sent to you containing a link to activate your ChemAxon Pass account.


  4. On the activation page, you need to specify a password.


  5. Finally, your ChemAxon Pass account is ready to use.


How to Generate an API Key

  1. Go to https://hub.chemaxon.com and sign in using GATE authenticationDo not enter any user name or password on this page.



  2. Then you are redirected to the GATE login page where you can use your Pass account (email address and password specified during Pass registration, see above).



  3. After a successfull login, click on your email address at the top right part of the site and select "Edit Profile" from the dropdown list.



  4. In the "Authentication Settings" section, click on the cog wheel icon next to the input field called "API Key". If you already have an API Key (the input field is filled and there are two more icons next to the cog wheel icon), you can skip this step.



  5. The API key can be revealed by clicking on the eye icon.



  6. Copy the API key to use as the password credential during build.

How to Congfigure Your Project

Gradle

If you would like to use Gradle as your build tool, you can follow these instructions to access ChemAxon Maven repository. Or you can use the quickstart project as an example.

In your Gradle project, create (or edit if already exists) a gradle.properties file and add these contents. You can also move this file outside your project, into <user home>/.gradle directory.

artifactory_user=[the email address coresponding to your ChemAxon Pass account, see above]
artifactory_password=[the API key you generated, see above]
artifactory_contextUrl=https://hub.chemaxon.com/artifactory

In the build.gradle file, add our Maven repoitory in the repositories block. For example,

repositories {
    maven {
        url hubRepositoryUrl
        credentials {
            username = hubUser
            password = hubPassword
        }
    }
}

After applying these settings, you can add ChemAxon modules as dependencies.

npm

The ChemAxon npm repository with frequent releases is hosted on hub.chemaxon.com under the npm-local repository, which also includes with a virtual cache to the official npmjs.org public registry. If you'd like to install a ChemAxon npm package, you can follow the "Set me up" guide of Artifactory for the npm-local repository. The guide will walk you through obtaining the authentication token and configuration for the repository. 


curl -o ~/.npmrc -u<email address>:<api key> https://hub.chemaxon.com/artifactory/api/npm/auth
npm config set registry https://hub.chemaxon.com/artifactory/api/npm/npm-local

Quickstart Projects

Gradle

A simple, self-contained quickstart project example using Gradle:

MSketchGradleQuickstart.zip

Maven

A simple, self-contained quickstart project example using Apache Maven:

MSketchMavenQuickstart.zip

Top Level Modules

To integrate a product, you only need to add its top-level module as dependency, all required modules will be downloaded transitively.

ProductTop-level module name in repository
Marvinmarvin-app
JChemjchem-main

Example Projects

JKlustor Web Example

An open-source API usage example for JKlustor, which uses ChemAxon Maven Repository. It is available on GitHub: https://github.com/ChemAxon/jklustor-web-example/

 

  • No labels