# getSubstitutes

**Identifier:** `vidal_getSubstitutes`

**Provider:** [VIDAL France](https://kirha.com/providers/vidal.md)

Find alternatives via one of four modes: generic (répertoire ANSM), hybrid (ANSM 2024), biosimilar, or foreign (same ATC, another country).

## Run it with the CLI

```bash
kirha tools run vidal_getSubstitutes \
  --input '{
    "drugUri": "<drugUri>",
    "mode": "generic"
  }'
```

`--input` takes a JSON object that matches the input schema. Pass `--input -` to read it from stdin.

## Call it over HTTP

```bash
curl https://api.kirha.com/tools/v1/execute \
  --request POST \
  --header 'Content-Type: application/json' \
  --header 'Authorization: **********' \
  --data '{
  "tool_name": "vidal_getSubstitutes",
  "input": {
    "drugUri": "<drugUri>",
    "mode": "generic"
  }
}'
```

Replace the stars with an API key from https://app.kirha.com/api-keys.

## Input schema

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "countryCode": {
      "description": "ISO-3166 alpha-2; required when mode=foreign",
      "maxLength": 2,
      "minLength": 2,
      "type": "string"
    },
    "drugUri": {
      "description": "From searchDrugs.uris[] (product scope)",
      "pattern": "^vidal:\\/\\/product\\/[A-Za-z0-9_-]+$",
      "type": "string"
    },
    "limit": {
      "default": 25,
      "maximum": 50,
      "minimum": 1,
      "type": "number"
    },
    "mode": {
      "enum": [
        "generic",
        "hybrid",
        "biosimilar",
        "foreign"
      ],
      "type": "string"
    }
  },
  "required": [
    "drugUri",
    "mode"
  ],
  "type": "object"
}
```

## Output schema

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "additionalProperties": false,
  "properties": {
    "alternativeUris": {
      "items": {
        "type": "string"
      },
      "type": "array"
    },
    "alternatives": {
      "items": {
        "additionalProperties": false,
        "properties": {
          "activePrinciples": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "foreignCountry": {
            "additionalProperties": false,
            "properties": {
              "code": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            },
            "required": [
              "code"
            ],
            "type": "object"
          },
          "genericType": {
            "type": "string"
          },
          "laboratory": {
            "type": "string"
          },
          "marketStatus": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "uri": {
            "type": "string"
          }
        },
        "required": [
          "uri",
          "name"
        ],
        "type": "object"
      },
      "type": "array"
    },
    "context": {
      "type": "string"
    },
    "group": {
      "additionalProperties": false,
      "properties": {
        "comment": {
          "type": "string"
        },
        "differentiation": {
          "type": "string"
        },
        "hybridReferent": {
          "type": "boolean"
        },
        "inscriptionDate": {
          "type": "string"
        },
        "medicalSituation": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "radiationDate": {
          "type": "string"
        },
        "referentUri": {
          "type": "string"
        },
        "substitutable": {
          "type": "boolean"
        },
        "uri": {
          "type": "string"
        }
      },
      "required": [
        "uri"
      ],
      "type": "object"
    },
    "mode": {
      "enum": [
        "generic",
        "hybrid",
        "biosimilar",
        "foreign"
      ],
      "type": "string"
    },
    "sourceProduct": {
      "additionalProperties": false,
      "properties": {
        "name": {
          "type": "string"
        },
        "uri": {
          "type": "string"
        }
      },
      "required": [
        "uri",
        "name"
      ],
      "type": "object"
    }
  },
  "required": [
    "context",
    "sourceProduct",
    "mode",
    "alternatives",
    "alternativeUris"
  ],
  "type": "object"
}
```

## Related tools

Other VIDAL France tools that this tool refers to, or that refer to it.

- [`searchDrugs`](https://kirha.com/providers/vidal/searchDrugs.md)

-----

[All VIDAL France tools](https://kirha.com/providers/vidal.md) · [< Back to tools list](https://kirha.com/tools.md)