gaodengyun/goldencloud-sdk-php

金特克开放平台 PHP SDK

dev-main 2021-01-21 01:37 UTC

This package is auto-updated.

Last update: 2024-09-10 14:52:46 UTC


README

PHP Golden Cloud API SDK

1.

composer require gaodengyun/goldencloud-sdk-php dev-main

2.

require "./vendor/autoload.php";

use Goldencloud\Client;

$route = "/tax-api/invoice/wait-open/v1";

$config = [
    'host' => 'HOST',
    'appkey' => 'APPKEY',
    'secret' => 'SECRET',
    'route' => $route

];

$arg = [
    "taxpayer_num" => "20181010000000865115391398242493",
    "machine_no" => "125523523523",
    "invoice_type_code" => "026"
];

$client = new \Goldencloud\Client($config);
$res = $client->postObject($arg);
var_dump($res);