https://github.com/commercetools/rest-modeling-framework
The rest modeling framework provides an EMF based model for RAML api definition files.
https://github.com/commercetools/rest-modeling-framework
audit-sdk
Last synced: about 1 year ago
JSON representation
The rest modeling framework provides an EMF based model for RAML api definition files.
- Host: GitHub
- URL: https://github.com/commercetools/rest-modeling-framework
- Owner: commercetools
- License: mit
- Created: 2017-07-13T15:17:51.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2024-07-22T21:10:47.000Z (almost 2 years ago)
- Last Synced: 2025-04-20T15:17:59.304Z (about 1 year ago)
- Topics: audit-sdk
- Language: Java
- Homepage:
- Size: 2.08 MB
- Stars: 9
- Watchers: 3
- Forks: 2
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
The rest modeling framework provides an EMF based model for RAML api definition files.
### Using in your own project
The latest unstable release can be retrieved from [Maven](https://search.maven.org/artifact/com.commercetools.rmf/rest-modeling-framework) with:
```gradle
ext {
rmfVersion = "0.2.0-20240722205528"
}
sourceCompatibility = 1.8
dependencies {
compile "com.commercetools.rmf:raml-model:${rmfVersion}"
}
```
The main entry point is the `io.vrap.rmf.raml.model.RamlModelBuilder` class, see the following code for an example on how to use it:
```java
final URI fileURI = URI.createFileURI("/path/api.raml");
final RamlModelResult modelResult = new RamlModelBuilder().buildApi(fileURI);
final List validationResults = modelResult.getValidationResults();
if (validationResults.isEmpty()) {
final Api api = modelResult.getRootObject();
}
```
### Docker
To start the RMF generator using docker use the following command
```
docker run --rm -v:/api -v:/out vrapio/rmf-generator -l postman /api/update-actions.raml
```