# Get revision metadata

RevisionMetadata returns metadata for a specific revision of the application.

Endpoint: GET /gitops/api/v1/agents/{agentIdentifier}/applications/{query.name}/revisions/{query.revision}/metadata
Version: 1.0
Security: x-api-key

## Path parameters:

  - `agentIdentifier` (string, required)
    Agent identifier for entity.

  - `query.name` (string, required)
    the application's name

  - `query.revision` (string, required)
    the revision of the app

## Query parameters:

  - `accountIdentifier` (string)
    Account Identifier for the Entity.

  - `orgIdentifier` (string)
    Organization Identifier for the Entity.

  - `projectIdentifier` (string)
    Project Identifier for the Entity.

  - `query.appNamespace` (string)
    the application's namespace.

  - `query.project` (string)

  - `query.sourceIndex` (integer)
    source index (for multi source apps).

  - `query.versionId` (integer)
    versionId from historical data (for multi source apps).

## Response 200 fields (application/json):

  - `author` (string)

  - `date` (object)
    Time is a wrapper around time.Time which supports correct
marshaling to YAML and JSON.  Wrappers are provided for many
of the factory methods that the time package offers.

+protobuf.options.marshal=false
+protobuf.as=Timestamp
+protobuf.options.(gogoproto.goproto_stringer)=false

  - `date.seconds` (string)
    Represents seconds of UTC time since Unix epoch
1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to
9999-12-31T23:59:59Z inclusive.

  - `date.nanos` (integer)
    Non-negative fractions of a second at nanosecond resolution. Negative
second values with fractions must still have non-negative nanos values
that count forward in time. Must be from 0 to 999,999,999
inclusive. This field may be limited in precision depending on context.

  - `tags` (array)

  - `message` (string)

  - `signatureInfo` (string)
    SignatureInfo contains a hint on the signer if the revision was signed with GPG, and signature verification is enabled.

  - `references` (array)
    References contains references to information that's related to this commit in some way.

  - `references.commit` (object)
    CommitMetadata contains metadata about a commit that is related in some way to another commit.

  - `references.commit.author` (string)
    Author is the author of the commit, i.e. git show -s --format=%an .
Must be formatted according to RFC 5322 (mail.Address.String()).
Comes from the Argocd-reference-commit-author trailer.

  - `references.commit.date` (string)
    Date is the date of the commit, formatted as by git show -s --format=%aI (RFC 3339).
It can also be an empty string if the date is unknown.
Comes from the Argocd-reference-commit-date trailer.

  - `references.commit.subject` (string)
    Subject is the commit message subject line, i.e. git show -s --format=%s.
Comes from the Argocd-reference-commit-subject trailer.

  - `references.commit.body` (string)
    Body is the commit message body minus the subject line, i.e. git show -s --format=%b.
Comes from the Argocd-reference-commit-body trailer.

  - `references.commit.sha` (string)
    SHA is the commit hash.
Comes from the Argocd-reference-commit-sha trailer.

  - `references.commit.repoUrl` (string)
    RepoURL is the URL of the repository where the commit is located.
Comes from the Argocd-reference-commit-repourl trailer.
This value is not validated and should not be used to construct UI links unless it is properly
validated and/or sanitized first.

## Response default fields (application/json):

  - `error` (string)

  - `code` (integer)

  - `message` (string)

  - `details` (array)

  - `details.type_url` (string)
    A URL/resource name that uniquely identifies the type of the serialized
protocol buffer message. This string must contain at least
one "/" character. The last segment of the URL's path must represent
the fully qualified name of the type (as in
path/google.protobuf.Duration). The name should be in a canonical form
(e.g., leading "." is not accepted).

In practice, teams usually precompile into the binary all types that they
expect it to use in the context of Any. However, for URLs which use the
scheme http, https, or no scheme, one can optionally set up a type
server that maps type URLs to message definitions as follows:

* If no scheme is provided, https is assumed.
* An HTTP GET on the URL must yield a [google.protobuf.Type][]
  value in binary format, or produce an error.
* Applications are allowed to cache lookup results based on the
  URL, or have them precompiled into a binary to avoid any
  lookup. Therefore, binary compatibility needs to be preserved
  on changes to types. (Use versioned type names to manage
  breaking changes.)

Note: this functionality is not currently available in the official
protobuf release, and it is not used for type URLs beginning with
type.googleapis.com. As of May 2023, there are no widely used type server
implementations and no plans to implement one.

Schemes other than http, https (or the empty scheme) might be
used with implementation specific semantics.

  - `details.value` (string)
    Must be a valid serialized protocol buffer of the above specified type.


