tams-sdk
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

TAMS SDK

English | 中文

Environment Support

  • Node.js

Install

npm install tams-sdk --save
yarn add tams-sdk
pnpm add tams-sdk

Usage

import { TamsSDK, Sha256RsaAuthenticateStrategy } from "tams-sdk";
import fs from "node:fs";

// your private key
const content = fs.readFileSync("./private_key.pem", "utf-8");

const sdk = new TamsSDK({
  appId: "YOUR_APP_ID",
  authenticateStrategy: new Sha256RsaAuthenticateStrategy(content),
});

async function main() {
  await sdk.v1.tamsApiV1ServiceGetModel("MODEL_ID");

  await sdk.uploadFile({
    file: fs.readFileSync('./Slogan.png')
  })

  // ...
}

main();

Readme

Keywords

none

Package Sidebar

Install

npm i tams-sdk

Weekly Downloads

1

Version

1.0.0

License

ISC

Unpacked Size

158 kB

Total Files

8

Last publish

Collaborators

  • zhuscat