{"id":18950242,"url":"https://github.com/salesforce/anypoint-automation-client-generator","last_synced_at":"2025-04-16T00:31:33.985Z","repository":{"id":36991709,"uuid":"350462203","full_name":"salesforce/anypoint-automation-client-generator","owner":"salesforce","description":"OAS specifications for Anypoint Platform Resources","archived":false,"fork":false,"pushed_at":"2024-02-06T14:37:40.000Z","size":280,"stargazers_count":4,"open_issues_count":0,"forks_count":10,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-04-08T00:12:24.010Z","etag":null,"topics":["generator","openapi","openapi3","swagger"],"latest_commit_sha":null,"homepage":"","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/salesforce.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-03-22T19:19:01.000Z","updated_at":"2024-01-31T07:04:10.000Z","dependencies_parsed_at":"2024-01-13T02:58:11.763Z","dependency_job_id":"dfa0c571-bad6-45e2-a3a4-b572d9b2032a","html_url":"https://github.com/salesforce/anypoint-automation-client-generator","commit_stats":null,"previous_names":["salesforce/anypoint-automation-client-generator"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salesforce%2Fanypoint-automation-client-generator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salesforce%2Fanypoint-automation-client-generator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salesforce%2Fanypoint-automation-client-generator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/salesforce%2Fanypoint-automation-client-generator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/salesforce","download_url":"https://codeload.github.com/salesforce/anypoint-automation-client-generator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223690197,"owners_count":17186574,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["generator","openapi","openapi3","swagger"],"created_at":"2024-11-08T13:21:58.278Z","updated_at":"2024-11-08T13:21:59.126Z","avatar_url":"https://github.com/salesforce.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cloudhub API Client Generator\n\n## Install\n\nMake sure to install nodejs and npm and execute the following in the root project\n\n```bash\nnpm install\n```\n\n## Execute generator\n\nMake sure to add `ANYPOINT_GENERATOR_GO_DEST` environment variable that should point to the destination go folder. You can use the `dist` folder of the project which is ignored in git by executing the following inside the project's folder:\n\n```bash\nexport ANYPOINT_GENERATOR_GO_DEST=`pwd`/dist\n```\n\nUse the following to get the manual\n\n```bash\nnpx openapi-generator-cli help\n```\n\nUse the following command to generate using the configuration stored in `openapitools.json`\n\n```bash\nnpx openapi-generator-cli generate\n```\n\n## How to write your spec ?\n\nHere's some rules to keep in mind when you write your spec:\n\n* Use OAS 3.0.0\n* Define your objects schemas in `#/components/schema` and reference them in your path definitions.\n* Use enheritance and polymorphism when you define your schemas to avoid redefining the same attributes multiple times. [ref](https://swagger.io/docs/specification/data-models/inheritance-and-polymorphism/).\n* For each attribute of your schemas make sure to provide a `title`. The `title` will be used to generate a structure name for that attribute, therefore use a short and consitent name. look in the existent specs for examples.\n* Use **caml case** in `title` to name your schemas attributes.\n* When using `title` to describe an object or array, its name should be unique accross the same specification.\n* For each of your api resource, return a deterministic result and never user OneOf for example. The generator will not be able to create the appropriate Type.\n* For all simple types (e.g integer, string ...) Don't use `$ref` to refer to the definition.\n* Make sure to remove any unnecessary `required` attributes.\n* Though the use of body parameter is discouraged for `DELETE` operations, some APIs may require it (to delete multiple specific items for example...). In that case some editors like Swagger may show an error when you add a `requestBody` on a `DELETE` resource operation. Don't pay attention to that error since our code generator supports it. If you are annoyed by that, try using your favorite editor's plugin for openapi (example on vscode openapi [plugin](https://marketplace.visualstudio.com/items?itemName=42Crunch.vscode-openapi)).\n* If a given field supports multiple types, don't use `oneOf` or `anyOf`. Instead, leave the type empty (add title field or description only for example).\n* Use `operationId` to name resources..\n\n## Reference\n\n* [open api generator](https://openapi-generator.tech/)\n* [openapi placeholders maven](https://github.com/OpenAPITools/openapi-generator/blob/master/modules/openapi-generator-maven-plugin/README.md)\n* [openapi cli placeholders](https://github.com/OpenAPITools/openapi-generator-cli/tree/master/apps/generator-cli/src#available-placeholders)\n* [JSON to JSONSchema Converter Tool](https://www.jsonschema.net/home)\n\n## Disclaimer\n\n**This is an [open source software, please review the considerations](LICENSE.md).**\nThis is an open source project, it does not form part of the official MuleSoft product stack, and is therefore not included in MuleSoft support SLAs. Issues should be directed to the community, who will try to assist on a best endeavours basis. This application is distributed **as is**.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsalesforce%2Fanypoint-automation-client-generator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsalesforce%2Fanypoint-automation-client-generator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsalesforce%2Fanypoint-automation-client-generator/lists"}