Quickbooks gateway guide
Additional notes |
---|
Quickbooks uses OAuth 2.0 to authenticate and authorize requests. Follow the instructions here to retrieve your client_id and client_secret , as well as your initial refresh_token and access_token . Since the access_token expires every 60 minutes, Spreedly will attempt to refresh the token using the refresh_token you provided when you set up your gateway, and will update these values for you as they are regenerated. However, once your refresh_token fully expires, you’ll need to follow the linked instructions again, and update your gateway with the new refresh_token . |
Adding a Quickbooks gateway
To add a Quickbooks gateway, use the credentials you obtained above:
curl https://core.spreedly.com/v1/gateways.xml \
-u 'C7cRfNJGODKh4Iu5Ox3PToKjniY:4UIuWybmdythfNGPqAqyQnYha6s451ri0fYAo4p3drZUi7q2Jf4b7HKg8etDtoKJ' \
-H 'Content-Type: application/xml' \
-d '<gateway>
<gateway_type>quickbooks</gateway_type>
<client_id>client_id</client_id>
<client_secret>client_secret</client_secret>
<refresh_token>refresh_token</refresh_token>
<access_token>access_token</access_token>
</gateway>'
<gateway>
<token>twJhdLh1I3Nsi6qhv1d7dQoGpt</token>
<gateway_type>quickbooks</gateway_type>
<name>Quickbooks</name>
<description nil="true"/>
<characteristics>
<supports_purchase type="boolean">true</supports_purchase>
<supports_authorize type="boolean">true</supports_authorize>
<supports_capture type="boolean">true</supports_capture>
<supports_credit type="boolean">true</supports_credit>
<supports_general_credit type="boolean">false</supports_general_credit>
<supports_void type="boolean">true</supports_void>
<supports_adjust type="boolean">false</supports_adjust>
<supports_verify type="boolean">false</supports_verify>
<supports_reference_purchase type="boolean">false</supports_reference_purchase>
<supports_purchase_via_preauthorization type="boolean">false</supports_purchase_via_preauthorization>
<supports_offsite_purchase type="boolean">false</supports_offsite_purchase>
<supports_offsite_authorize type="boolean">false</supports_offsite_authorize>
<supports_3dsecure_purchase type="boolean">false</supports_3dsecure_purchase>
<supports_3dsecure_authorize type="boolean">false</supports_3dsecure_authorize>
<supports_3dsecure_2_mpi_purchase type="boolean">false</supports_3dsecure_2_mpi_purchase>
<supports_3dsecure_2_mpi_authorize type="boolean">false</supports_3dsecure_2_mpi_authorize>
<supports_store type="boolean">false</supports_store>
<supports_remove type="boolean">false</supports_remove>
<supports_fraud_review type="boolean">true</supports_fraud_review>
</characteristics>
<credentials>
</credentials>
<gateway_settings>
</gateway_settings>
<gateway_specific_fields>
</gateway_specific_fields>
<payment_methods>
<payment_method>credit_card</payment_method>
</payment_methods>
<state>retained</state>
<redacted type="boolean">false</redacted>
<created_at type="dateTime">2019-11-04T22:08:01Z</created_at>
<updated_at type="dateTime">2019-11-04T22:08:01Z</updated_at>
</gateway>
To learn more about creating and managing gateways in our Marketplace, review the Gateway user guide. For gateways not included in the Marketplace, review the steps below.
Create a gateway
Visit your Connections area to review all gateways and add new ones. When creating your gateways, select the gateway name and authentication mode (if prompted) before completing required fields. Select ☑️Sandbox to create a gateway in Sandbox mode, for processing test card data and transactions in your Spreedly environment.
After following Quickbooks' instructions for OAuth setup, enter your client_id
, client_secret
and access_token
with your initial refresh_token
to create a new Quickbooks gateway. Spreedly will attempt to use this refresh token as long as it exists, but you will need to follow the setup instructions again and update your gateway with another refresh token each time it expires.
Updated 5 months ago