--- title: Conditional metafields APIs - Shopify developer changelog description: >- Shopify’s developer changelog documents all changes to Shopify’s platform. Find the latest news and learn about new platform opportunities. source_url: html: 'https://shopify.dev/changelog/conditional-metafields-apis' md: 'https://shopify.dev/changelog/conditional-metafields-apis.md' metadata: effectiveApiVersion: 2024-07 affectedApi: - displayName: Admin GraphQL API handle: admin-graphql primaryTag: displayName: API handle: api secondaryTag: displayName: New handle: new indicatesActionRequired: false createdAt: '2024-06-10T10:14:39-04:00' postedAt: '2024-07-01T10:14:00-04:00' updatedAt: '2024-06-17T14:36:15-04:00' effectiveAt: '2024-07-01T10:14:00-04:00' --- July 1, 2024 Tags: * Admin GraphQL API * 2024-07 # Conditional metafields APIs As of `2024-07`, we've added APIs for viewing and filtering conditional metafield definitions such as product attributes: * Use the `constraints` field on `MetafieldDefinition` to view the metafield definition's constraints. * Use the `constraintSubtype` argument on the `metafieldDefinitions` and `standardMetafieldDefinitionTemplates` queries to retrieve only metafield definitions that apply to the passed constraint subtype. * Use the `constraintStatus` argument on the `metafieldDefinitions` and `standardMetafieldDefinitionTemplates` queries to filter based on whether the metafield definitions are constrained. [Learn more about conditional metafields](https://shopify.dev/docs/apps/build/custom-data/metafields/definitions/conditional-metafield-definitions)