BitGo / api-ts

Type- and runtime- safe TypeScript APIs
https://bitgo.github.io/api-ts
Other
15 stars 21 forks source link

feat: support custom codec files in host repositories #870

Closed ad-world closed 1 month ago

ad-world commented 1 month ago

DX-658

This ticket adds support for types packages to define schemas for their own custom codecs (that are defined with t.Type or other un-supported primitives).

To make use of this feature in the types package, first create a file titled openapi-gen.config.js. Then, add the following to the package.json in the package "customCodecFile": "openapi-gen.config.js". Then, you can populate the file with your schemas like this:

module.exports = E => {
    return { 
         CustomSchema: () => E.right({ type: 'string' })
    }
}
github-actions[bot] commented 1 month ago

:tada: This PR is included in version @api-ts/openapi-generator@4.30.0 :tada:

The release is available on npm package (@latest dist-tag)

Your semantic-release bot :package::rocket:

github-actions[bot] commented 3 weeks ago

:tada: This PR is included in version @api-ts/io-ts-http@3.2.0 :tada:

The release is available on npm package (@latest dist-tag)

Your semantic-release bot :package::rocket:

github-actions[bot] commented 3 weeks ago

:tada: This PR is included in version @api-ts/express-wrapper@1.0.30 :tada:

The release is available on npm package (@latest dist-tag)

Your semantic-release bot :package::rocket:

github-actions[bot] commented 3 weeks ago

:tada: This PR is included in version @api-ts/superagent-wrapper@1.3.0 :tada:

The release is available on npm package (@latest dist-tag)

Your semantic-release bot :package::rocket:

github-actions[bot] commented 3 weeks ago

:tada: This PR is included in version @api-ts/typed-express-router@1.1.10 :tada:

The release is available on npm package (@latest dist-tag)

Your semantic-release bot :package::rocket: