Web Page Design and Hosting

May 3, 2007

Open the text file in a text editor

Filed under: professional development with web apis — webmaster @ 12:15 pm

At this point, you must convert the .p12 certificate into the type of certificate required by your program- ming language. For example, to use the PayPal API from Visual Studio .NET, you convert the .p12 certifi- cate to a .CER certificate. To do so, you first should double-click the previously created my_paypal_cert.p12file. The Certificate Import Wizard appears. Follow the prompts to import the certificate, specifying yourcertificate password when prompted. Accept the defaults, and a message should appear indicating that theimport was successful. Next, after the wizard completes, you export the .p12 certificate from Internet Explorer to a .CER file. Todo so, open Internet Explorer, and then select Tools.Internet Options and select the Content tab. Clickthe Certificates button and select the .p12 certificate that you use to access the Sandbox. It should appearon the Personal tab. Click the Export button, and a Certificate Export Wizard appears. Follow the wizardto accept the defaults, and on the File to Export screen, select Browse and specify the path and filenamefor the new certificate. Click Save to save the file and follow the prompts to finish the wizard. It isimportant that you keep track of the name and location where you saved the .CER file because you willneed it in calls to the API later on. Anatomy of a PayPal API QueryNow that you have all the messy setup out of the way, let s take a look at how a PayPal API query isstructured. You then see a simple example of how to execute queries using the API. Query SyntaxCurrently, you can call one of four methods of the PayPal API: RefundTransaction, TransactionSearch, GetTransactionDetails, and MassPay. Each of these is covered detail. RefundTransactionThe RefundTransactionmethod is used to request a payment refund. ARefundTransactionRequestis an object that is passed to the RefundTransactionmethod and supports the following properties: .TransactionId Required. Unique identifier for a transaction. .RefundType Type of refund. Currently Fullor Partial. .Amount Amount of refund. Required if partial refund. .Memo Custom comment about the refund. The RefundTransactionmethod responds by returning a RefundTransactionResponseobject. TransactionSearchThe TransactionSearchmethod requests a historical transaction search. Up to 100 exact matches canbe retrieved. Various criteria can be specified to limit the search results. The following properties aresupported by the TransactionSearchRequestobject that is passed to the TransactionSearchmethod: .StartDate Required. Starting date range to use for search. .End Date Ending date range to use for search. 158Chapter

Note: If you are looking for good and high quality web space to host and run your application check Lunarwebhost Cheap Web Hosting services


No Comments

No comments yet.

RSS feed for comments on this post. TrackBack URI

Sorry, the comment form is closed at this time.

Powered by Java Web Hosting