I used razorpay but not working so please fix this

Topic summary

A developer is encountering errors while implementing Razorpay payment integration with Shopify’s GraphQL API.

Initial Problem:

  • The orderCapture mutation fails with “Field ‘payments’ doesn’t exist on type ‘Order’”
  • Original attempt used paymentGatewayId parameter with Razorpay payment ID

Troubleshooting Steps:

  • Another user suggested using parentTransactionId instead of paymentGatewayId
  • After making this change, a new error emerged: “Invalid global id ‘pay_NQmaLp5p0FBqZ6’”
  • The error indicates the Razorpay payment ID format is incompatible with Shopify’s expected global ID format

Current Status:

  • The issue remains unresolved
  • The developer’s final response contains only emoji characters, suggesting frustration
  • No working solution has been identified for properly formatting the Razorpay transaction ID for Shopify’s API
Summarized with AI on November 12. AI used: claude-sonnet-4-5-20250929.

QUERY:-
mutation {
orderCapture(input: {
amount: “870.00”,
currency: “IN”,
id: “gid://shopify/Order/5649145266461”,
paymentGatewayId: “pay_NQmaLp5p0FBqZ6”
}) {
transaction {
id
}
userErrors {
field
message
}
}
}

ERROR:-

{
“errors”: [
{
“message”: “Field ‘payments’ doesn’t exist on type ‘Order’”,
“locations”: [
{
“line”: 7,
“column”: 5
}
],
“path”: [
“query”,
“order”,
“payments”
],
“extensions”: {
“code”: “undefinedField”,
“typeName”: “Order”,
“fieldName”: “payments”
}
}
]
}

use parentTransactionId instead of paymentGatewayId

{
“errors”: [
{
“message”: “Invalid global id ‘pay_NQmaLp5p0FBqZ6’”,
“locations”: [
{
“line”: 3,
“column”: 23
}
],
“path”: [
“mutation”,
“orderCapture”,
“input”,
“parentTransactionId”
],
“extensions”: {
“code”: “argumentLiteralsIncompatible”,
“typeName”: “CoercionError”
}
}
]
}

:-1: :-1: :-1: :-1: :-1: :-1: :-1: :-1: :-1: :-1: :-1: :-1: :-1: