Skip to main content

publishResourceType

form schema
[DEPRECATED]

Transitional shim from V0 publishArtifactDefinition during the migration to OCI-hosted resource types. Prefer the OCI-native publishing flow; this mutation may be removed without notice.

Deprecated — use at your own risk. This mutation exists only to bridge V0's publishArtifactDefinition into V2 while resource types are being migrated to OCI. New integrations should use the OCI-native publishing flow. This mutation may be removed or change behavior without notice.

Upsert a resource type from a JSON Schema document. If an existing resource type in your organization has the same $md.name, its schema is replaced; otherwise a new resource type is created.

The schema describes the shape of data this resource type exposes to dependents. It must include a $md extension that declares the type's identifier ($md.name), display label, icon, and UI behavior.

mutation {
publishResourceType(
organizationId: "your-org-id"
input: {
schema: {
"$md": { name: "aws-iam-role", label: "AWS IAM Role" }
type: "object"
properties: { data: { type: "object", required: ["arn"], properties: { arn: { type: "string" } } } }
}
}
) {
successful
result { id name }
messages { field message }
}
}
publishResourceType(
organizationId: ID!
input: PublishResourceTypeInput!
): ResourceTypePayload @deprecated

Arguments

publishResourceType.organizationId ● ID! non-null scalar {#organization-id}

Your organization's unique identifier.

publishResourceType.input ● PublishResourceTypeInput! non-null input {#input}

Upsert a resource type for your organization from a JSON Schema document. If an existing resource type has the same identifier, its schema is replaced. Deprecated: this mutation exists solely to bridge V0 publishArtifactDefinition into the V2 API while resource types are being migrated to OCI. New integrations should use the OCI-native publishing flow — this mutation may be removed without notice.

Type

ResourceTypePayload object