GoldMoney
holding no.   passphrase          
      forgot passphrase?  
  Why Buy Gold & Silver? How It Works About Us   Rates Sign Up
Automated Batch Payments Help
 
You can automatically make a single payment or multiple payments from your Holding (without manually logging into your Holding) by performing the following steps:
 
1 Write a script or program, for example using PERL, PHP or Visual Basic, that will create text consisting of lines in the following format:
PMT<TAB><holding_number><TAB><passphrase><TAB><reference_number>
						
<holding_number_to_pay><TAB><goldgram_code=0><TAB><amount_to_pay><TAB><memo>
...(repeat the previous line for each payment you want to make)
where:
  • PMT = the name of the service being requested (PMT indicates a single payment or multiple payments);
  • <holding_number> = the number of your Holding in the format XX-XX-XX-X;
  • <passphrase> = the current passphrase of your Holding;
  • <reference_number> = an optional reference number that the GoldMoney system will include in the response;
  • <TAB> = the TAB character (ASCII 0x09).
and for each payment:
  • <holding_number_to_pay> = the number of the Holding to pay in the format XX-XX-XX-X;
  • <goldgram_code=0> = 0 (zero) to indicate a goldgram payment;
  • <amount_to_pay> = the goldgram amount to pay;
  • <memo> = a memo to associate with the payment;
  • <TAB> = the TAB character (ASCII 0x09).
2 Programmatically submit the text, as an HTML form field using the HTTP POST method, to the following URL:

https://secure.goldmoney.com/user/auto.php

Prior to submission, you must also explicitly set/override the Content-Type field in the HTTP header to application/x-www-form-urlencoded. Various libraries exist that enable you to programmatically send HTTP messages and override HTTP headers, for example cURL (Linux) and MSINET (Microsoft). Depending on which library you use, you may need to explicitly construct the entire HTTP message header in your program (you do not need to do this when using cURL or MSINET).

Furthermore, the name of the HTML form field that contains the populated template must be set to either GM_AUTO or to gm_auto.
3 Interpret the result that is returned by the GoldMoney system. Your script or program should be written so that it can identify errors as follows:

If the response does not contain a set of <pre> </pre> tags, then a serious error occurred such as an HTTP timeout or an authentication error.

Alternatively, if the response contains a set of <pre> </pre> tags, then an error will be indicated by an [ERROR] tag. A description of the error will follow the [ERROR] tag.

The GoldMoney system will attempt to execute each payment contained in the request (regardless of whether a previous payment failed, if any). The response will indicate, for each payment, whether it was successful or not.
   
Open a free account to start buying gold and silver >> free signup
   

top of page © Copyright 2001-2008 Net Transactions Ltd.
Disclaimer | Privacy Policy | Customer Support | FAQ | CAP | Sitemap