CyberRXN Docs
APIСправочник API

Конвертер представлений

POST /v1/chemistry/convert-representation

POST /v1/chemistry/convert-representation

Все операции API · OpenAPI

Доступ

Требуется bearer-авторизация. Описание операции задаёт дополнительные права, роли и ограничения для сессий кабинета. Сам по себе API-ключ их не предоставляет.

Тело запроса

ПолеТипОбязательноОписание
datastringда
input_format"smiles" ∣ "inchi" ∣ "mol" ∣ "sdf" ∣ "reaction_smiles" ∣ "rxn"да
output_format"smiles" ∣ "inchi" ∣ "inchikey" ∣ "mol" ∣ "mol_v3000" ∣ "sdf" ∣ "reaction_smiles" ∣ "rxn" ∣ "rxn_v3000" ∣ "formula" ∣ "unicode_formula"да
allow_lossybooleanнетПо умолчанию: false.
Полная схема: ConvertRepresentationRequest
{
  "properties": {
    "data": {
      "type": "string",
      "maxLength": 20000,
      "minLength": 1,
      "title": "Data"
    },
    "input_format": {
      "type": "string",
      "enum": [
        "smiles",
        "inchi",
        "mol",
        "sdf",
        "reaction_smiles",
        "rxn"
      ],
      "title": "Input Format"
    },
    "output_format": {
      "type": "string",
      "enum": [
        "smiles",
        "inchi",
        "inchikey",
        "mol",
        "mol_v3000",
        "sdf",
        "reaction_smiles",
        "rxn",
        "rxn_v3000",
        "formula",
        "unicode_formula"
      ],
      "title": "Output Format"
    },
    "allow_lossy": {
      "type": "boolean",
      "title": "Allow Lossy",
      "default": false
    }
  },
  "additionalProperties": false,
  "type": "object",
  "required": [
    "data",
    "input_format",
    "output_format"
  ],
  "title": "ConvertRepresentationRequest"
}

Ответы

HTTPОписаниеТип
200Успешный ответapplication/json: RepresentationConversionResult
401Требуется авторизацияapplication/problem+json: ProblemDetails
402Недостаточно кредитовapplication/problem+json: ProblemDetails
403Доступ запрещёнapplication/problem+json: ProblemDetails
408Время запроса истеклоapplication/problem+json: ProblemDetails
413Превышен размер запросаapplication/problem+json: ProblemDetails
422Ошибка входных данныхapplication/problem+json: ProblemDetails
429Превышен лимитapplication/problem+json: ProblemDetails
502Ошибка шлюзаapplication/problem+json: ProblemDetails
503Сервис недоступенapplication/problem+json: ProblemDetails

Ответ: RepresentationConversionResult

ПолеТипОбязательноОписание
input_format"smiles" ∣ "inchi" ∣ "mol" ∣ "sdf" ∣ "reaction_smiles" ∣ "rxn"да
output_format"smiles" ∣ "inchi" ∣ "inchikey" ∣ "mol" ∣ "mol_v3000" ∣ "sdf" ∣ "reaction_smiles" ∣ "rxn" ∣ "rxn_v3000" ∣ "formula" ∣ "unicode_formula"да
kind"molecule" ∣ "molecule_collection" ∣ "reaction"да
record_countintegerда
outputstringда
recordsConvertedRepresentationRecord[]да
canonical_reaction_smilesstring ∣ nullда
lossybooleanда
warningsstring[]да
limitationsstring[]да
Полная схема
{
  "properties": {
    "input_format": {
      "type": "string",
      "enum": [
        "smiles",
        "inchi",
        "mol",
        "sdf",
        "reaction_smiles",
        "rxn"
      ],
      "title": "Input Format"
    },
    "output_format": {
      "type": "string",
      "enum": [
        "smiles",
        "inchi",
        "inchikey",
        "mol",
        "mol_v3000",
        "sdf",
        "reaction_smiles",
        "rxn",
        "rxn_v3000",
        "formula",
        "unicode_formula"
      ],
      "title": "Output Format"
    },
    "kind": {
      "type": "string",
      "enum": [
        "molecule",
        "molecule_collection",
        "reaction"
      ],
      "title": "Kind"
    },
    "record_count": {
      "type": "integer",
      "title": "Record Count"
    },
    "output": {
      "type": "string",
      "title": "Output"
    },
    "records": {
      "items": {
        "$ref": "#/components/schemas/ConvertedRepresentationRecord"
      },
      "type": "array",
      "title": "Records"
    },
    "canonical_reaction_smiles": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Canonical Reaction Smiles"
    },
    "lossy": {
      "type": "boolean",
      "title": "Lossy"
    },
    "warnings": {
      "items": {
        "type": "string"
      },
      "type": "array",
      "title": "Warnings"
    },
    "limitations": {
      "items": {
        "type": "string"
      },
      "type": "array",
      "title": "Limitations"
    }
  },
  "additionalProperties": true,
  "type": "object",
  "required": [
    "input_format",
    "output_format",
    "kind",
    "record_count",
    "output",
    "records",
    "canonical_reaction_smiles",
    "lossy",
    "warnings",
    "limitations"
  ],
  "title": "RepresentationConversionResult"
}

Эта страница генерируется из OpenAPI. Примеры показывают схемы, а не вымышленные успешные ответы.

Расход и оплата · Типизированные ошибки

На этой странице