Skip to content

IceWhaleTech/IceWhale-OpenAPI

Repository files navigation

IceWhale-OpenAPI

This Git repository is all IceWhale's OpenAPI Documentation. including:

API V2 is our latest API, but it not contain all API. some operation is in V1 yet.

ZimaOS OpenAPI Live Preview

CasaOS OpenAPI Live Preview

How to use

Use in Javascript/Typescript

you can find npm package in npmjs.com such as:

npm install @icewhale/zimaos-localstorage-openapi
import { StorageMethodsApi } from '@icewhale/zimaos-localstorage-openapi'
...
export const storageApi = new StorageMethodsApi(configuration, '/v2/local_storage', axios)
...
storageApi.getDisk()

Golang

you can use the openapi.yaml file to generate the API code.

such as, add the following code to the header of your main.go file

//go:generate bash -c "mkdir -p codegen/local_storage && go run github.com/deepmap/oapi-codegen/cmd/[email protected] -generate types,client -package local_stroage https://raw.githubusercontent.com/IceWhaleTech/IceWhale-OpenAPI/main/zimaos-local-storage/local_storage/openapi.yaml > codegen/local_storage/api.go"

then run the following command to generate the API code.

go generate

Other Language

you can use the openapi.yaml file to generate the API code.

Contributing

the repo is mirror of OpenAPI of IceWhale's project. if you want to modify the API, please go to the project's repo to modify.

License

MIT

Contact

Feel free to contact us by Issue.