@rss3/js-sdk
Advanced tools
Comparing version 0.0.1 to 0.4.0
{ | ||
"name": "@rss3/js-sdk", | ||
"type": "module", | ||
"version": "0.0.1", | ||
"version": "0.4.0", | ||
"main": "./dist/index.mjs", | ||
"module": "./dist/index.mjs", | ||
"types": "./dist/index.d.ts", | ||
"typesVersions": { | ||
"*": { | ||
"*": [ | ||
"./dist/*", | ||
"./dist/index.d.ts" | ||
] | ||
} | ||
}, | ||
"exports": { | ||
"./*": "./src/*" | ||
".": { | ||
"types": "./dist/index.d.ts", | ||
"require": "./dist/index.cjs", | ||
"import": "./dist/index.mjs" | ||
}, | ||
"./utils": { | ||
"types": "./dist/utils.d.ts", | ||
"require": "./dist/utils.cjs", | ||
"import": "./dist/utils.mjs" | ||
}, | ||
"./types": { | ||
"types": "./dist/types.d.ts", | ||
"require": "./dist/types.cjs", | ||
"import": "./dist/types.mjs" | ||
} | ||
}, | ||
"description": "js sdk for rss3 services", | ||
"files": [ | ||
"dist" | ||
], | ||
"dependencies": { | ||
"openapi-fetch": "^0.6.0" | ||
}, | ||
"devDependencies": { | ||
"@kecrily/eslint-config": "^0.2.6", | ||
"@types/node": "^20.3.2", | ||
"eslint": "^8.43.0", | ||
"typescript": "^5.0.4", | ||
"unbuild": "^1.2.1", | ||
"vitest": "^0.32.2" | ||
}, | ||
"eslintConfig": { | ||
"extends": "@kecrily", | ||
"ignorePatterns": [ | ||
"src/types/data.ts", | ||
"src/types/search.ts" | ||
] | ||
}, | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
}, | ||
"author": "", | ||
"license": "ISC" | ||
} | ||
"dev": "unbuild --stub", | ||
"build": "unbuild", | ||
"test": "vitest", | ||
"typecheck": "tsc --noEmit", | ||
"lint": "eslint . --cache" | ||
} | ||
} |
@@ -1,3 +0,54 @@ | ||
# Overview | ||
# index-sdk | ||
The JS SDK for rss3 services. | ||
index-sdk is designed to simplify the development process and enable developers to interact with RSS3 API efficiently | ||
## Usage | ||
```sh | ||
# npm | ||
npm i index-sdk | ||
# yarn | ||
yarn add index-sdk | ||
# pnpm | ||
pnpm add index-sdk | ||
``` | ||
If you want to customize the endpoint, you can: | ||
```ts | ||
import { IndexClient } from 'index-sdk' | ||
const index = new IndexClient({ endpoint: { data: 'https://test-pregod.rss3.dev/v1' } }) | ||
``` | ||
And of course you can also use [all of fetch options (`RequestInit`)](https://developer.mozilla.org/en-US/docs/Web/API/fetch#options). | ||
## Examples | ||
### Get all of Vitalik's profiles on Web3 | ||
```ts | ||
import { IndexClient } from 'index-sdk' | ||
const index = new IndexClient() | ||
const { result: profiles } = await index.profiles.get('vitalik.eth') | ||
``` | ||
Now you know where to find Vitalik! | ||
### Get all notes posted by DIYgod on xLog | ||
```ts | ||
import { IndexClient } from 'index-sdk' | ||
const index = new IndexClient() | ||
const { result: notes } = await index.notes.get('diygod.eth', { | ||
platform: ['xLog'] | ||
}) | ||
``` | ||
Now you can even use xLog as a headless CMS |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
No contributors or author data
MaintenancePackage does not specify a list of contributors or an author in package.json.
Found 1 instance in 1 package
No License Found
License(Experimental) License information could not be found.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Trivial Package
Supply chain riskPackages less than 10 lines of code are easily copied into your own project and may not warrant the additional supply chain risk of an external dependency.
Found 1 instance in 1 package
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
657881
13
13825
2
55
1
6
1
2
+ Addedopenapi-fetch@^0.6.0
+ Addedopenapi-fetch@0.6.2(transitive)