SOAP API
Getting started with SOAP API for Number
Our SOAP API allows full integration of Number services with a high degree of customization. You can use our SOAP API reference to learn about specific methods in the API.
Before you continue this section, we recommend reading sections about authentication, best practices, and input validation.
Generate the service for WCF applications
The easiest way to get started using Number's SOAP API is to generate the CardProcessClient service. Following the steps below, you'll learn how to generate that service for applications using the Windows Communication Foundation (WCF) framework.
Generate CardProcessService using the command line
CardProcessService using the command lineInstall .NET Framework SDK
Download and install the Windows SDK that corresponds with the version of the .NET Framework you're using. You can find the SDK installer on the Microsoft website.
Alternatively, you can install Visual Studio Community, Professional, or Enterprise, which include the SDK alongside with other .NET development tools.
Locate the ServiceModel Metadata Utility Tool is installed
SvcUtil.exe is used to generate service model code from metadata documents such as WSDL files. For .NET Framework 4.x, it is usually located in 'C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\'.
Use the tool to generate the CardProcessService model
CardProcessService modelOpen a Command Prompt window and navigate to the directory where SvcUtil.exe is located or add the directory to your system's PATH environment variable for easier access.
Then, you can execute the following command:
svcutil.exe https://easypay5.com/APIcardProcR119/CardProcAPI.svc?wsdlMake sure to run the command as an administrator. If you receive network errors, you can try downloading the single WSDL with the full service description and provide the file path as an argument to the command.
Example: svcutil.exe "C:\Users\{Name}\Downloads\CardProcAPI.xml"
This will generate a configuration file with the name of output.config and a C# code file named CardProcAPI.cs that contains the client class. Both of the files should appear inside of the folder with the tool.
Add the two files to your application and use the generated client class to call the service.
Here's a brief example of creating and disposing of the service client:
class Test
{
static void Main()
{
CardProcessClient client = new CardProcessClient();
// Use the 'client' variable to call operations on the service.
// Always close the client.
client.Close();
}
}Class Test
Shared Sub Main()
Dim client As CardProcessClient = New CardProcessClient()
' Use the 'client' variable to call operations on the service.
' Always close the client.
client.Close()
End Sub
End ClassExamples
Authenticate
An example of using the Authenticate method.
Process Annual Consent
An example of using ConsentAnnual_ProcPayment_Alt method
Void Transaction
An example of using Transaction_Void method.
Credit Transaction
An example of using Transaction_ApplyCredit method.
Query Transaction
An example of using Transaction_Query method.
Consent General Query
An example of using ConsentGeneral_Query method
Generate Receipt
An example of using ReceiptGenerate method.
Last updated
Was this helpful?