INTERNAL_SERVER_ERROR when fetching Subscription Contract with Lines via GraphQL

Solved

INTERNAL_SERVER_ERROR when fetching Subscription Contract with Lines via GraphQL

Jorge12
Shopify Partner
13 0 4

Hello,

I've recently had my custom app whitelisted for access to the new subscription APIs. 

I'm able to fetch Subscription Contracts for my store, so long as I'm requesting the basic id, status, createdAt, etc fields.  When I request the SubscriptionLines on the subscription contract, I get an internal error.

Has anyone else encountered this, or can a Shopify Dev check the logs for my request and see what's up?

Thank you!

 

 

Request:

 

 

 

 

 

query {
    subscriptionContracts(first: 10) {
        edges {
            node {
                id
                createdAt
                status
                lines(first: 10) {
                    edges{
                        node{
                            productId
                            quantity
                            sellingPlanId
                            sellingPlanName
                            sku
                            title
                            variantId
                            variantTitle
                        }
                    }
                }
            }
        }
    }
}

 

 

 

 

 

 

Response:

 

 

 

 

 

{
    "errors": [
        {
            "message": "Internal error. Looks like something went wrong on our end.\nRequest ID: 868c320d-5154-44bd-8117-ebfe4932e371 (include this in support requests).",
            "extensions": {
                "code": "INTERNAL_SERVER_ERROR",
                "requestId": "868c320d-5154-44bd-8117-ebfe4932e371"
            }
        }
    ]
}

 

 

 

 

Accepted Solution (1)
ewalker
Shopify Staff
34 4 7

This is an accepted solution.

Hi Jorge12, this should now be fixed.

To learn more visit the Shopify Help Center or the Community Blog.

View solution in original post

Replies 6 (6)

ewalker
Shopify Staff
34 4 7

I believe this is due to a bug that has since been resolved. Can you confirm that your same query no longer returns an error?

To learn more visit the Shopify Help Center or the Community Blog.

Jorge12
Shopify Partner
13 0 4

Thanks for the update, however I'm experiencing the same issue still in our production store. 

A test store that we spun up in December via the Partner dashboard executes the same query successfully without issue.  I don't know if the state of our production store is in some way compromised?   

Here is the same request/response from production run just now today.  Removing the "lines" portion makes the query execute as expected.

 

Request:

query {
  subscriptionContracts(first: 10) {
    edges {
      node {
        id
        lines(first: 10) {
            edges{
            node{
                id
            }
            }
        }
      }
    }
  }
}

Response:

{
    "errors": [
        {
            "message": "Internal error. Looks like something went wrong on our end.\nRequest ID: 2e397314-a46c-4697-91a9-a5956f88f854 (include this in support requests).",
            "extensions": {
                "code": "INTERNAL_SERVER_ERROR",
                "requestId": "2e397314-a46c-4697-91a9-a5956f88f854"
            }
        }
    ]
}

 

colinloretz
Excursionist
16 2 7

Do you have any line items that are linked to a productVariant that is now in draft status or been deleted?

ewalker
Shopify Staff
34 4 7

Hi 

To learn more visit the Shopify Help Center or the Community Blog.

ewalker
Shopify Staff
34 4 7

This is an accepted solution.

Hi Jorge12, this should now be fixed.

To learn more visit the Shopify Help Center or the Community Blog.

Jorge12
Shopify Partner
13 0 4

Perfect, I just confirmed it's fixed.  Thanks for seeing this through to a fix!!