Web Logo Designphp website development
Web Marketing
Live Chat | Request a Quote
 

Cogniter Blog

Musings on design, development, and digital marketing

A Guide to Input File Structure used in Royal Bank of Canada’s ACH Direct Payments

FRIDAY, AUGUST 11, 2017

ACH Direct Payments is one of the five methods available to the Royal Bank of Canada (RBC) commercial account holders accepting regular payments from their clients. It eases receivables management for businesses but for developers, working with ACH Direct Payments is a challenge.

Imagine no pre-built SDKs, no sandbox environment, and no API interface. You are supposed to work under these constraints and be perfect because money is involved. The challenge is huge but not insurmountable.

We wrote 3 Techniques to Simplify Working with Royal Bank of Canada’s ACH Direct Payments for developers who are working with this payment system for the first time. This blog is a continuation of that series. Today we will share with you the Input File Structure.
What is an Input File? And Why Should You Care?
The RBC’s servers accept data as Flat, EDI, or XML files. These files are also known as input files because they contain the information that identifies a customer, such as her name, address, transaction amount, etc.

The Input Files follow a strict format which has been detailed on the RBC’s official website. Any deviation from the recommended standard may lead to bugs, or worse. Avoid such a scenario with our overview.

Input Files are Divided into Sections or Records
An input data file is divided into separate sections some of which store the file’s purpose and identify its type. Each file contains a record in each line. In a line character position is used to identify the starting and ending of different kinds of data. For example, the first 16 characters can carry a person’s first name, the second set of 16 characters can store an account holder’s last name, and the third set of 16 characters can represent a client’s account balance.

Four Essential Records
Each payment file has at least four kinds of records:

1.    Routing Record
2.    Header Record
3.    Basic Payment Record
4.    Trailer Record

Let’s view them one at a time.

Routing Record
The very first record in an input file, used by the RBC to decide if the information is a credit or a debit file. Each line in this record stores:

1.    File type: credit or debit
2.    File format
3.    File’s purpose: test or real-life
4.    File’s length, which can be 152 or 80 characters

The characters are put together in a fixed format which looks like:


•    Green tells whether a record is a debit or a credit file. AAPA will mean you want to collect money from customers and AAPD refers to the transfer money from you to your customers.
•    Orange tells the format of the file to be followed and the length of each record. Here, it tells that the input data file is in standard format and the length of the record should be 152 characters per line.
•    Blue text marks the record as a test file, so it will not be processed in production environment.
•    Red “NL” specifies that the records will span the full length of the standard i.e. 152, other possible value for NL is the 80. In that case, records length could be 80 characters.

Header Record
Header record explains the details of basic payment records, such as: How many payment records are included? And what is file creation number and file creation date?

A file creation number is the unique number assigned to each input data file that you create. This number can be used to identify the data from the reports produced by the RBC.

ACH Direct Payments is a batch processing system. The RBC does not respond immediately. So do not upload multiple input data files if you don’t notice an immediate response. Responses will appear after an interval of 4–5 hours.

The file creation number and file creation date are a good candidate to identify the response and associate it with your input data file for further automating the payment process.

The header record also contains the client’s number and name. Once you sign up for an RBC account capable of processing ACH payments, you are assigned two client numbers both having a different functionality. The first is used in your debit file and the second in your credit file.

•    For everything to work as planned, it is important to ensure a valid combination of Routing Record and client numbers is used in the Header Record.
•    Apart from all this, it’s crucial to stick to the format touched upon Routing Record.
•    Header Record follows Routing Record in the data file.

Routing and header records would look like the one below inside your flat input data file before encryption.

 

Basic Payment Record
Basic payment record is the actual payment transaction record. These are the individual’s monetary transactions that can be processed through RBC if the developer has access to data, such as a customer’s banking information, record number, customer number, amount to be deducted, and currency information.

To uniquely identify a payment and to backtrack (confirm) it from our own database we used the file creation number, customer number, and payment number field to create a unique number.

Then the fields can be used in the output data file (reports) from RBC to track the success and failure of the payments. You need to make sure that you have correctly placed the data in their required columns in your flat file as per the format guides. Otherwise, you are going to get errors back in the report. If you get error back from RBC you can check the proper reason on this link https://www.rbcroyalbank.com/ach/cid-212259.html

Some columns would have less data than the actual character length allows. In such a case, you would have to pad those places with blank value. You will get the padding and filler instructions inside the guides. Your basic payment record would look like the one below:

 

Trailer Record
Trailer record is the last record in the file. This record tells that how many payment records there are in the file and what the total payment amount is. The trailer record will look something like this.

 

Your completed non-encrypted file would look like the one below:

 
After the input data file has been created, encrypt it using public-key encryption and then upload it to the SFTP location for the RBC to process. When you upload the input data file to RBC it will automatically detect the new file and process it. Usually it takes few hours to schedule the processing of the file and provide you results back.

Below is the sample code to upload the input data file to RBC SFTP. This code is in PHP and is using cURL extension of PHP.



Conclusion
We hope that this post will get you started on the way to developing a solid understanding of Input Data files. For questions and suggestions, feel free to comment or write to us at cogniter@cogniter.com.

Posted By Chetan at
Like Cogniter on Facebook Share on Google+ Cogniter on Pin It
Label(s):  

3 Techniques to Simplify Working with Royal Bank of Canada's ACH Direct Payments

TUESDAY, JUNE 20, 2017

 Commercial account holders at the Royal Bank of Canada (RBC) can stay on top of receivables—who has paid and who still owes them—through ACH Direct Payments, RBC Express Incoming Wires Reporting, Electronic Chargeback, Corporate Creditor Bill Payment Service, and Whole Lockbox. For a developer, working with any of these systems is a challenge but none poses more difficulties than ACH Direct Payments.
 
As if the absence of pre-built SDKs wasn’t a challenge in itself, for some unfathomable reason the RBC decided to go a step further and complicate things even more by not providing a sandbox environment and an API interface. So when a Canadian client asked us to integrate ACH Direct Payments with his website so he could accept recurring payments, we knew we had an uphill task in front of us. Nonetheless, we accepted the challenge. Two months later the system is up and working without a hitch.
 
Yet another successful and on-time delivery. Yet another happy client. But we wanted more this time… for you. So we asked our star developers, who worked on integrating ACH Direct Payments with a website, to share three techniques that will make future developers’ job easier.
 
If you have a Canadian client wanting to collect payments from her customers on a regular basis through the RBC’s ACH Direct Payments, reading these three tips can save you hours of frustration.
 

Technique 1: Keep Things Simple

The RBC provides five connectivity methods and accepts three data formats.
 
Connectivity Methods Data File Formats
1.      RBC Express File Transfer
2.      Secure FTP ?
3.      Connect: Direct Secure+
4.      A/P Link / Receivables Link
5.      AS2
1.      Flat Files ?
2.      EDI Files
3.      XML Files

In our experience, Secure FTP is the simplest way to connect to the RBC’s servers and Flat Files is the most straightforward format.
 
In fact, for our implementation, we opted for Secure FTP (SFTP) and if you choose SFTP, like us, you will need an IP, a username, a password, and a port to connect. As to the data files, they will be uploaded and stored on the RBC server. The server will then process your input files to create a report data file. The report data file will be placed in a different folder on the same server.
 

Technique 2: Understand Data Files

Payments in the RBC environment are handled through input data files, one type for receiving and the other for transferring the funds. An input data file is divided into separate sections some of which store the file’s purpose and identify its type.  Each file has at least four kinds of records:

1.      Routing Record
2.      Header Record
3.      Basic Payment Record
4.      Trailer Record
 
Although the data layout in the files has been standardized by the RBC (https://www.rbcroyalbank.com/ach/cid-212260.html), the absence of samples and references still pose a challenge in formatting. To ease things, we have created a short guide explaining Input Data files.
 

Technique 3: Stick to the Data File Structure on the RBC Server

Data files are uploaded and stored on the RBC server for processing. The input files are stored in /inbound and the output data—that is produced after server processing—is kept in /outbound/AAPA or /outbound/AAPD; the exact location dependant on whether the input file is a credit or a debit.
 
This overview of the directory structure will help you create a mental map:
/inbound
/outbound/AAPA
/outbound/AAPD
0.

Takeaway


Working with ACH Direct Payments is not easy. Keep things simple. Stick with the simplest connectivity method and file format, take time to understand Data File structure, and follow the data file structure on the RBC server. It will reduce the probability of bugs sneaking in and you can deliver the project in time.
 
 

Posted By chetan at
Like Cogniter on Facebook Share on Google+ Cogniter on Pin It
Label(s):  

3 Advanced Google Search Features for Webmasters

TUESDAY, APRIL 11, 2017

When it comes to technology, digital marketing in 2017 is lightyears ahead of traditional marketing. Google, Facebook, and other Silicon Valley companies have gathered so much data about consumers that—if you have access to the right tools—you can easily promote colour books to new parents, market flagship smartphones to high-flying executives, or find clients interested in your services right from your couch.

A lot of these powerful marketing tools require you to subscribe to a plan, but others are completely free. Google Search is one of the most powerful free research tools available to webmasters. Well utilized, it can provide content ideas, help you in keyword research, and tell you how your competitors are performing.
Take me to the Nth Link

Let’s start with a challenge we all can relate to: How to see beyond the hype?

The large platforms—Twitter, Facebook, Google, and others—are geared towards providing you the latest, the most shared content for each of your search queries which comes handy if that’s what you are looking for.

However, if you want to discover sites that just don't make it to the top of the search engine results for whatever reason and access that wealth of untapped information, develop a habit to append Google search URL with &start=NUMBER, where NUMBER is the top ranking websites you want to remove from search results. You can enter any integer between 0 and 999 and it will work.


cogniterBlogStartFunction.jpg


Million Short is a nice alternative if you want to remove more than 1000 top links. Its interface is easier, too, and you don’t feel like coding.

Show Me x Results on a Page

This feature is related to &start=NUMBER and can be used with it. We are all aware that you can tell Google to display more than 10 results on a page. Set your preferences and voila! All your future search queries will display the results you want to see.

cogniterBlogPreferences.jpg


So far, so good.

But what if you want to see, let’s say, 50 results for one keyword and 70 for another. Changing Preferences is really a cumbersome way to go about it. A convenient method is to append &num=NUMBER to the search URL. The NUMBER can be between 0 and 100. For instance, &num=25 will return the top 25 results for a search query.

cogniterBlogNumFunction.jpg

When used with &search=NUMBER, &num=NUMBER can be really powerful. The above image shows you the links ranking between 51 and 55 for the search query “life on Mars.”

Limit Results from a Country

Google’s Advanced Search allows you to limit your results to websites hosted in a specific country. The trouble is the ease of use, or its lack thereof.

Every time you want to limit your search to a country, you will have to access Advanced Search and select the country from a dropdown. It’s OK if you need country-specific result once or twice in a day. But if you are a webmaster, your frequency will be much higher.

A faster alternative will be to append &cr=countryUK or &cr=countryUS. These tags will limit your results to the UK or the US. Tags are available for most countries.

cogniterBlogCountry.jpg
I Search From provides a more powerful and user friendly tool for country-specific search. You can even choose your device and city. An excellent way to see how your website is performing locally.

Takeaway

Google Search is a powerful tool that can make a lot of everyday SEO tasks easier. Don’t discount it. In upcoming posts, we will reveal more powerful features of Google.



Posted By Chetan at
Like Cogniter on Facebook Share on Google+ Cogniter on Pin It
Label(s):  

When Does Content Outsourcing to India Work?

THURSDAY, FEBRUARY 09, 2017

When it comes to outsourcing content creation to India, almost everyone has a horror story to share; sloppy grammar, non-persuasive writing, foreign idioms, incorrect jargon, or a finished piece that just does not sound like the voice of your business. The list can be long and easily convince a business owner to hire only native writers or move content production in-house. Neither is panacea.
 
Hiring native writers can solve language issues but it will still be difficult to find someone who can write like you would. Any writer, native or not, will take time to learn the lingo of your trade and adopt your voice. In-house content writing can solve quality problems arising out of poor knowledge of your business but it can be prohibitively expensive. Not to mention the HR issues that arise from hiring and retaining talent.

Outsource to India or US, or Hire In-House?


Each strategy—outsource to India, outsource to the US, and hire an in-house writer—has its pros and cons.


 

Outsource to India

Outsource in the US

Hire a Writer Full-time

Cost

Low

Medium        

High

English skills

Varies

High

High

Writing skills

Varies

Varies

Varies

Industry knowledge

Varies

Varies

Can be acquired quickly

Cultural awareness

Little

High

High



Relying solely on any one of them will either lead to content that is not in line with your goals or make your content marketing financially unsustainable. Given this choice, what can a business do?

A lot. You can outsource content creation and still get quality work without overshooting your budget. Large companies, including Google, have Asian writers on their payroll at least since 2006. No one can claim hiring writers from India has put a dent in the quality of their documentation. If Google can pull it off, you can too.

What Can Businesses Do?


Besides the obvious—hire university educated writers with many years of experience or take your business only to the people with an excellent track record—there are less conspicuous but equally important areas you can work on. To start with, you can be a part of the team.


Become a Subject Matter Expert

It will time-consuming for you to write everything and letting your writer to do all the work saves you time but does not always produce desire results. Donning an editor’s hat is a sweet spot you can aspire to fill.

Go beyond hiring and providing an overview of your business when you outsource. You are the subject matter expert. You know your business better than anyone. You know what kind of writing it will take to help you grow. Share your knowledge before letting your writer do some research and produce a copy.

The first copy you will receive is unlikely to be perfect. It rarely happens. There are a few things you can do here:
  1. Hire a new writer because you did not like the first copy.
  2. Write the whole thing yourself.

Neither is a good strategy.

Hiring a new writer will only repeat another cycle of frustration. You may be pressed for time, especially if your business is in its early stages.

The right strategy is to edit the document and share your input with the writer who can then produce a nicer copy. After a few rounds you will have a polished copy which is usable and which can help you in expanding your business.

This process of improvement with iteration is quick, but it is neither as expensive as hiring a full-time in-house writer.

Know What You Need Content For

Did you ask your writer to create a keyword-rich blog on how awesome your products are? The chances are the blog will be mediocre and unlikely to be of any use to your customers. Ten years ago, blogs filled to the brim with keywords were all the rage. The era is behind us.

Content Outsourcing to india.

Contemporary readers want useful stuff. They do not want to read barely legible, convoluted texts. As a business owner you will have to listen to your readers if you want to survive and thrive.

Sit down with a marketing manager to find out the best way to reach out to your clients: mail, social media, blogs, articles, or e-books. Once a strategy is in place, you can go ahead and hire writers. That will leave neither of you undecided and you will have useful metrics to measure content performance.
Takeaway

US businesses have been outsourcing content creation to India for more than 15 years; a lot of them successfully. You can also cut costs and get quality content from India if you put in some effort and have a clear vision of how the content will be used and success measured.

Cogniter Technologies has been in the business of content writing since 2003. Working with Cogniter can help you reduce marketing costs and maintain quality. Write to us at infor@cogniter.com to know more.
Posted By chetan at
Like Cogniter on Facebook Share on Google+ Cogniter on Pin It
Label(s):  
 
< Previous  Page: 1 of 36 

Blogs by Categories

Blogs by Years

Recent Posts