> ## Documentation Index
> Fetch the complete documentation index at: https://veryfront.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Resolve current style artifact (legacy)

> Resolve style artifact.

`currentStyleArtifact(input: StyleArtifactSelectorInput!): ProjectStyleArtifact!`

Requires project.files.read.

**Deprecated.** Style artifacts are served on REST only.

Use Get style artifact (`getStyleArtifact`) on REST instead.

**Deprecated:** Use the REST operation getStyleArtifact. (CR-style-artifact-graphql-fields)

## Arguments

| Argument | Type | Required |
| - | - | - |
| `input` | [`StyleArtifactSelectorInput!`](https://veryfront.com/docs/cloud/graphql/types/styleartifactselectorinput) | Yes |

## Input fields

### input

[`StyleArtifactSelectorInput`](https://veryfront.com/docs/cloud/graphql/types/styleartifactselectorinput)

| Field | Type | Required | Description |
| - | - | - | - |
| `projectReference` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | No | Project ID or slug. Required unless projectId is supplied. |
| `projectId` | [`ID`](https://veryfront.com/docs/cloud/graphql/types/id) | No | Deprecated: Use projectReference. |
| `styleProfileHash` | [`String!`](https://veryfront.com/docs/cloud/graphql/types/string) | Yes | Style profile hash, a non-empty string. |
| `branch` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | No | Exactly one of branch, environmentName, or releaseId is required. |
| `environmentName` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | No | |
| `releaseId` | [`ID`](https://veryfront.com/docs/cloud/graphql/types/id) | No | |

## Response

Returns [`ProjectStyleArtifact!`](https://veryfront.com/docs/cloud/graphql/types/projectstyleartifact). Open the type for its fields and nested types.

| Field | Type | Description |
| - | - | - |
| `status` | [`StyleArtifactStatus!`](https://veryfront.com/docs/cloud/graphql/types/styleartifactstatus) | Current metadata state: ready, missing, building, or failed. |
| `artifactHash` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | Registered CSS artifact hash, or null when unavailable. |
| `assetPath` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | Registered CSS asset path, or null when unavailable. |
| `etag` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | Registered CSS asset entity tag, or null when unavailable. |
| `contentType` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | Registered CSS asset MIME type, or null when unavailable. |
| `buildRunId` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | Style build run identifier, or null when unavailable. |
| `failureReason` | [`String`](https://veryfront.com/docs/cloud/graphql/types/string) | Persisted failure detail, or null when unavailable. |
| `updatedAt` | [`DateTime`](https://veryfront.com/docs/cloud/graphql/types/datetime) | Most recent metadata update timestamp, or null for missing metadata. |

Types marked with `!` cannot be null. Lists use `[Type]` notation. The [type index](https://veryfront.com/docs/cloud/graphql/schema.md) lists all published input and response types.

## Example

```graphql title="query.graphql" theme={null}
query CurrentStyleArtifact($input: StyleArtifactSelectorInput!) {
  currentStyleArtifact(input: $input) {
    status
    updatedAt
    artifactHash
    assetPath
    buildRunId
  }
}
```

```json title="variables.json" theme={null}
{
  "input": {
    "projectReference": "00000000-0000-4000-8000-000000000001",
    "styleProfileHash": "example"
  }
}
```

<details>
  <summary>Try this query</summary>

  Calls use `https://api.veryfront.com/graphql`. Replace sample values with resources you can access. See [Authentication](https://veryfront.com/docs/cloud/authentication.md) for credentials and permissions.

  Bearer token or API key

  Stored in this tab's session. Clear credential

  Query

  Variables (JSON)
</details>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.