---
title: "Get artifact version metadata by content"
method: POST
path: "/groups/{groupId}/artifacts/{artifactId}/meta"
tags: ["Metadata"]
---

# Get artifact version metadata by content

`POST /groups/{groupId}/artifacts/{artifactId}/meta`

## Request

- The document declares no server URL.
- Auth: none declared

Gets the metadata for an artifact that matches the raw content.  Searches the registry
for a version of the given artifact matching the content provided in the body of the
POST.

This operation can fail for the following reasons:

* Provided content (request body) was empty (HTTP error `400`)
* No artifact with the `artifactId` exists (HTTP error `404`)
* No artifact version matching the provided content exists (HTTP error `404`)
* A server error occurred (HTTP error `500`)

## Query parameters

- `canonical` boolean

## Request body

- ArtifactContent
  - `content` string, required: Raw content of the artifact or a valid (and accessible) URL where the content can be found.
  - `references` ArtifactReference[], required: Collection of references to other artifacts.
    - `groupId` string, required
    - `artifactId` string, required
    - `version` string
    - `name` string, required

## Response `200`

The metadata of the artifact version matching the provided content.

- VersionMetaData
  - `version` string, required
  - `name` string
  - `description` string
  - `createdBy` string, required
  - `createdOn` string, date-time, required
  - `type` string, required
  - `globalId` integer, required
  - `state` 'ENABLED' | 'DISABLED' | 'DEPRECATED': Describes the state of an artifact or artifact version. The following states are possible: * ENABLED * DISABLED * DEPRECATED
  - `id` string, required: The ID of a single artifact.
  - `labels` string[]
  - `properties` Properties: User-defined name-value pairs. Name and value must be strings.
  - `groupId` string: An ID of a single artifact group.
  - `contentId` integer, required

## Other responses

- `401`: Common response for all operations that can return a `401` error indicating authentication is required.
- `403`: Common response for all operations that can return a `403` error indicating the user is authenticated but not authorized.
- `404`: Common response for all operations that can return a `404` error.
- `500`: Common response for all operations that can fail with an unexpected server error.

## Changes

> 65 revisions in range; 1 not diffed.

- **2023-03-28** (v2) `d0590df8d721`: 2 info
  - added the media type `application/get.extended+json` to the request body
  - added the media type `application/vnd.get.extended+json` to the request body
- **2023-02-02** (v2) `5152639bee96`: 1 info
  - the request's body type was generalized from no type to `string`, and format from no format to `binary`
- **2022-11-24** (v2) `29b79a1c2c74`: 10 info
  - removed the `ASYNCAPI` enum value from the `type` response property for the response status `200`
  - removed the `AVRO` enum value from the `type` response property for the response status `200`
  - removed the `GRAPHQL` enum value from the `type` response property for the response status `200`
  - removed the `JSON` enum value from the `type` response property for the response status `200`
  - …6 more
- **2022-04-25** (v2) `d1a3061ccc48`: 1 info
  - the request's body type was generalized from `string` to no type, and format from `binary` to no format
- **2021-05-05** (v2) `d3f0f99883aa`: 1 breaking, 1 info
  - removed the media type `application/json` from the request body
  - added the media type `*/*` to the request body

[Operation history](https://skmtc.dev/apicurio/apis/apicurio-registry-api-v2/changes/groups/:groupId/artifacts/:artifactId/meta/post.md)

---

[API](https://skmtc.dev/apicurio/apis/apicurio-registry-api-v2.md) - [All operations](https://skmtc.dev/apicurio/apis/apicurio-registry-api-v2/llms.txt) - [OpenAPI document](https://skmtc.dev/apicurio/apis/apicurio-registry-api-v2/revisions/8c48f413fa1f?raw)
