The compliance test suite for IPFS Pinning Service API Spec
Disclaimer: It is recommended to use an auth_token
separate from your production/live services. The compliance checks will do their best not to corrupt any existing pins you have, but consistent tests without consistent data is challenging.
npx @ipfs-shipyard/pinning-service-compliance -s <pinning_service_endpoint> <auth_token>
npm ci
npm run build
npm start -- -s $API_ENDPOINT $ACCESS_TOKEN
# or multiple endpoints
npm start -- -s $API_ENDPOINT1 $ACCESS_TOKEN1 -s $API_ENDPOINT2 $ACCESS_TOKEN2
To debug problems, you should use the -d
flag, and the dev-start
script:
npm run dev-start -- -s $API_ENDPOINT $ACCESS_TOKEN
A compliance check consists of:
- An API call
- A Payload
- An expected response
- A summary
To avoid setting secrets by hand:
cp .env-copy .env
Then replace all variables with the appropriate endpoints and tokens
Licensed under either of
- Apache 2.0, (LICENSE-APACHE / http://www.apache.org/licenses/LICENSE-2.0)
- MIT (LICENSE-MIT / http://opensource.org/licenses/MIT)
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.