---
name: "Swagger2::Editor"
section: "3pm"
platform: "linux"
package: "libswagger2-perl"
version: "0.77-1"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/Swagger2::Editor"
---

# Swagger2::Editor(3pm)

A WEB based Swagger2 API editor

## NAME

Swagger2::Editor - A WEB based Swagger2 API editor

## DESCRIPTION

Swagger2::Editor is a WEB based Swagger2 API editor.

## SYNOPSIS

```
  $ mojo swagger2 edit /path/to/api.json --listen http://*:3000
```

## ATTRIBUTES

### specification\_file

Returns path to swagger specification file. Defaults to `"SWAGGER_API_FILE"` environment variable.

## ROUTES

### GET /

Will render the editor and any Swagger specification given as input.

Can also just render the POD if requested as `"/.txt"` instead.

### POST /

Will parse the JSON/YAML in the HTTP body and render it as POD.

## METHODS

### startup

Used to set up the "ROUTES".

## COPYRIGHT AND LICENSE

Copyright (C) 2014-2015, Jan Henning Thorsen

This program is free software, you can redistribute it and/or modify it under the terms of the Artistic License version 2.0.

## AUTHOR

Jan Henning Thorsen - `"jhthorsen@cpan.org"`
