Unexpected GraphQL response

firetail:graphql-unexpected-response

Type:

Observation

Rule Severity:

Not Applicable

GraphQL response is not a JSON object.

GraphQL responses are typically expected to be JSON objects containing data and optional error information. This error commonly arises when the server returns a response in a format that deviates from the GraphQL specification, such as plain text, HTML, or a different data format, which prevents proper parsing and handling by the client application. Addressing this issue involves ensuring that the server consistently adheres to GraphQL's expected JSON response structure to facilitate correct data consumption and processing by client-side applications.

Remediation

Investigate server logs to determine the root cause for this.

Example Attack Scenario

How to Identify with Example Scenario

How to Resolve with Example Scenario

How to Identify with Example Scenario

Find the text in bold to identify issues such as these in API specifications

How to Resolve with Example Scenario

Modify the text in bold to resolve issues such as these in API specifications
References:

More findings

All Findings