Anchor to customerPaymentMethodPaypalBillingAgreementCreatecustomer
customerPaymentMethodPaypalBillingAgreementCreate
mutation
Requires access scope. Also: Requires
scope.
Creates a PayPal billing agreement for a customer.
Anchor to Arguments
Arguments
- Anchor to billingAddressbilling•
Address The billing address.
- Anchor to billingAgreementIdbilling•
Agreement Id String!required The billing agreement ID from PayPal that starts with 'B-' (for example,
).
- Anchor to customerIdcustomer•
Id ID!required The ID of the customer.
- Anchor to inactiveinactive•BooleanDefault:false
Whether the PayPal billing agreement is inactive.
Was this section helpful?
Anchor to CustomerPaymentMethodPaypalBillingAgreementCreatePayload returnsCustomerPaymentMethodPaypalBillingAgreementCreatePayload returns
- Anchor to customerPaymentMethodcustomer•
Payment Method The customer payment method.
- Anchor to userErrorsuser•
Errors The list of errors that occurred from executing the mutation.
Was this section helpful?
Mutation Reference
1mutation customerPaymentMethodPaypalBillingAgreementCreate($billingAddress: MailingAddressInput, $billingAgreementId: String!, $customerId: ID!, $inactive: Boolean) {2 customerPaymentMethodPaypalBillingAgreementCreate(billingAddress: $billingAddress, billingAgreementId: $billingAgreementId, customerId: $customerId, inactive: $inactive) {3 customerPaymentMethod {4 # CustomerPaymentMethod fields5 }6 userErrors {7 field8 message9 }10 }11}
Input
1{2 "billingAddress": {3 "address1": "<your-address1>",4 "address2": "<your-address2>",5 "city": "<your-city>",6 "company": "<your-company>",7 "countryCode": "",8 "firstName": "<your-firstName>",9 "lastName": "<your-lastName>",10 "phone": "<your-phone>",11 "provinceCode": "<your-provinceCode>",12 "zip": "<your-zip>"13 },14 "billingAgreementId": "<your-billingAgreementId>",15 "customerId": "gid://shopify/<objectName>/10079785100",16 "inactive": true17}
{
"billingAddress": {
"address1": "<your-address1>",
"address2": "<your-address2>",
"city": "<your-city>",
"company": "<your-company>",
"countryCode": "",
"firstName": "<your-firstName>",
"lastName": "<your-lastName>",
"phone": "<your-phone>",
"provinceCode": "<your-provinceCode>",
"zip": "<your-zip>"
},
"billingAgreementId": "<your-billingAgreementId>",
"customerId": "gid://shopify/<objectName>/10079785100",
"inactive": true
}
input MailingAddressInput {
address1: String
address2: String
city: String
company: String
country: String
countryCode: CountryCode
firstName: String
id: ID
lastName: String
phone: String
province: String
provinceCode: String
zip: String
}