Skip to main content

Get detailed statistics of an own Extension

GET/v2/contributors/{contributorId}/extensions/{extensionId}/statistics
API version
v2
Request method
GET
Operation ID
extension-get-own-extension-statistics

Request​

  • contributorIdstringrequired
  • extensionIdstring (uuid)required

Responses​

Format
application/json
Description

Detailed statistics of your own extension.

  • amountOfInstancesinteger (≥ 0)required

    The exact amount of instances of this extension, regardless of their state.

  • variantsarray of objectrequired

    Every variant of the extension's current price plan with its amount of instances, also variants without instances. Instances of a variant that is no longer part of the price plan, or without a chosen variant, only count towards amountOfInstances.

    • Array[
      • *object
        • amountOfInstancesinteger (≥ 0)required
        • variantobjectrequired

          A variant of an extension's price plan.

          • deletionDeadlinestring (date-time)
          • descriptionstring
          • isBookingStoppedbooleanrequired

            If a variant is no longer bookable the existing extension instances will not be removed but no new ones can be created.

          • isDeletionScheduledbooleanrequired
          • keystringrequired
          • namestring
          • priceInCentsintegerrequired

            The monthly price in Euro Cents before tax.

      ]
Content-Type: application/json

{
"amountOfInstances": 42,
"variants": [
{
"amountOfInstances": 12,
"variant": {
"deletionDeadline": "1985-10-26T01:21:00.000Z",
"description": "string",
"isBookingStopped": true,
"isDeletionScheduled": true,
"key": "string",
"name": "string",
"priceInCents": 123
}
}
]
}
{
"properties": {
"amountOfInstances": {
"description": "The exact amount of instances of this extension, regardless of their state.",
"example": 42,
"minimum": 0,
"type": "integer"
},
"variants": {
"description": "Every variant of the extension's current price plan with its amount of instances, also variants without instances. Instances of a variant that is no longer part of the price plan, or without a chosen variant, only count towards amountOfInstances.",
"items": {
"properties": {
"amountOfInstances": {
"example": 12,
"minimum": 0,
"type": "integer"
},
"variant": {
"description": "A variant of an extension's price plan.",
"properties": {
"deletionDeadline": {
"format": "date-time",
"type": "string"
},
"description": {
"type": "string"
},
"isBookingStopped": {
"description": "If a variant is no longer bookable the existing extension instances will not be removed but no new ones can be created.",
"type": "boolean"
},
"isDeletionScheduled": {
"type": "boolean"
},
"key": {
"type": "string"
},
"name": {
"type": "string"
},
"priceInCents": {
"description": "The monthly price in Euro Cents before tax.",
"type": "integer"
}
},
"required": [
"key",
"priceInCents",
"isBookingStopped",
"isDeletionScheduled"
],
"type": "object"
}
},
"required": [
"variant",
"amountOfInstances"
],
"type": "object"
},
"type": "array"
}
},
"required": [
"amountOfInstances",
"variants"
],
"type": "object"
}

Usage examples​

$ curl \
--fail \
--location \
-H "Authorization: Bearer $MITTWALD_API_TOKEN" \
https://api.mittwald.de/v2/contributors/string/extensions/f0f86186-0a5a-45b2-aa33-502777496347/statistics
import { MittwaldAPIV2Client } from "@mittwald/api-client";
import { assertStatus } from "@mittwald/api-client-commons";

const client = MittwaldAPIClient.newWithToken(process.env.MITTWALD_API_TOKEN);
const response = await client.marketplace.extensionGetOwnExtensionStatistics({
"contributorId": "string",
"extensionId": "f0f86186-0a5a-45b2-aa33-502777496347"
});

assertStatus(response, 200);

use \Mittwald\ApiClient\Generated\V2\Clients\Marketplace\ExtensionGetOwnExtensionStatistics\ExtensionGetOwnExtensionStatisticsRequest;

$client = MittwaldAPIClient::newWithToken(getenv('MITTWALD_API_TOKEN'));

$request = (new ExtensionGetOwnExtensionStatisticsRequest(
contributorId: "string",
extensionId: "f0f86186-0a5a-45b2-aa33-502777496347"
));
$response = $client->marketplace()->extensionGetOwnExtensionStatistics($request);

var_dump($response->getBody();

On this page