Skip to content

Latest commit

 

History

History
49 lines (29 loc) · 1.74 KB

README.md

File metadata and controls

49 lines (29 loc) · 1.74 KB

PDC SDK Generators

This repository houses the infrastructure for generating PDC SDKs.

We're using a project called swagger-codegen to power our SDK, and this repository provides tooling and templates to make SDK generation easier in specifically supported languages.

Prequisites

  • JRE (18+)

Generating SDKs

To generate the SDKs supported by this project, you will need a Swagger specification located at the project root and named openapi.json. The current Swagger specification for the PDC can be found in the service repository.

Generating official SDKs:

  1. Clone the repository:
git clone git@github.com:PhilanthropyDataCommons/sdk.git
  1. Change directory:
cd sdk
  1. Copy your Swagger specification:
cp YOUR_SWAGGER_SPEC_LOCATION ./openapi.json
  1. Generate the code:
> ./gradlew generateSwaggerCode

The generated code will now exist in the build directory.

Each language target will have its own directory inside of build/, and you can follow the README instructions in that directory with additional steps related to that language's SDK.

  • Typescript: build/typescript/README.md

Generating other SDKs:

If you are interested in another language please review the many languages that the Swagger Codegen project supports directly. Please see the Swagger Codegen documentation for information on how to generate libraries for other languages.