Skip to content

val314159/raml-python

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

53 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Raml-python generator

This package uses raml-generator as a framework for generating macro files.

Installation (from npm)

You probably just want this, so type:

npm install raml-python -g

Usage (Command-line):

  raml-python-generator api.raml --output api-client

Options:
  --version     Show version number  [boolean]
  -o, --output  Output directory     [required]
  -d, --data    Provide the path to JSON package information

Usage (inline javascript):

var generator = require('raml-python');

var output = generator(/* raml, data */);

Installation (from source)

npm install . -g

Testability (from source)

raml-python-generator example/simple.raml -o simple
cp example/rpc_impl.py simple

If it's all good, this will generate a python package in the directory 'simple' for various python web clients and servers.

Try it out by running python -msimple.server_wsgi in one window, and python example/run_client.py in another.

For more details of what's generated, see the README.md in the './lib' folder.

Alternatively, check out The Simplest RAML File.

For an alternative language implementation (javascript), see https://github.com/mulesoft-labs/raml-javascript-generator.

License

Apache License 2.0

About

a RAML Python Code Generator - clients and servers

Resources

License

Stars

Watchers

Forks

Packages

No packages published