New York CNN Business  — 

As western companies jockey for a way into China’s enormous digital payments business, PayPal has clinched a license to provide digital payment services in China, following its acquisition of a majority stake in a Chinese payments company.

China’s central bank has approved PayPal’s acquisition of a 70% equity interest in GoPay, the companies announced Monday. PayPal says this makes it the first foreign firm licensed to provide digital payment services in China.

The terms of the deal, which is expected to close by the end of 2019, have not been disclosed, a PayPal spokesperson said. GoPay is a small Chinese payments provider that functions similarly to PayPal — it allows merchants to accept non-credit card payments straight from their websites.

American payment and credit card companies have for years been trying to break into the world’s second largest economy, where the growing middle class means a growing market of consumers seeking lending, credit card and money transfer services. In recent years, the Chinese government has opened the door to foreign firms to start applying for licenses to launch payments networks in the country, but the approval process has been slow-going. By taking on majority ownership of GoPay, PayPal acquired access to the Chinese firm’s license to provide online payment services.

“We look forward to partnering with China’s financial institutions and technology platforms, providing a more comprehensive set of payment solutions to businesses and consumers, both in China and globally,” PayPal CEO Dan Schulman said in a statement on LinkedIn.

The deal opens the door for PayPal to process digital transactions in China — which are estimated to total in the trillions. But it may not be an easy market to break into. Chinese digital payments services Alibaba (BABA)’s AliPay and Tencent (TCEHY)’s WeChat Pay have dominated that market, in part by making it easy for merchants to use their services and accept payments from mobile phones rather than setting up the infrastructure to accept credit card payments. As of last year, more than 8 million brick-and-mortar stores in China accepted AliPay.

The licensing requirements have made it difficult for American companies to operate in the country, while benefiting Chinese companies.

Only one other American company has successfully made inroads in the market. Last year, American Express received preliminary approval from the People’s Bank of China to start building out a domestic clearance and settlement network through its joint venture with Chinese partner LianLian group.

In every other market in the world, American Express processes transactions through its own, Arizona-based network. But in China, it’s had to rely on the state-controlled payments giant China Union Pay to process transactions. The preliminary approval it received last year will allow it to build out its own network to process payments on AmEx branded cards.

Mastercard and Visa have also tried to offer such services in China.