Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow loose JSON Schemas (additionalProperties: true) #383

Closed
splendf opened this issue Mar 23, 2015 · 1 comment
Closed

Allow loose JSON Schemas (additionalProperties: true) #383

splendf opened this issue Mar 23, 2015 · 1 comment

Comments

@splendf
Copy link

splendf commented Mar 23, 2015

Hi,

We will have some a field named metadata where the content will be defined by the user app.
metadata : {
"key1" : "value1",
"key2" : "value2",
etc.
}

Each key/value will be defined by the user. So how I can do that in SWAGGER Editor ?

Thx in advance,

@mohsen1
Copy link
Contributor

mohsen1 commented Mar 23, 2015

Your schema should be something like this:

  metadata:
    additionalProperties: true

But the form generator does not support "additionalProperties": true where you can add unlimited key/value pairs. For now if you put the request data in body you can provide raw json for the request.

I'll replace form generator with Angular JSON Schema Form where it's possible to have additionalProperties: true

@mohsen1 mohsen1 added this to the 2.9.4 milestone Apr 30, 2015
@mohsen1 mohsen1 changed the title Metadata with user-defined fields Allow loose JSON Schemas (additionalProperties: true) May 7, 2015
@mohsen1 mohsen1 modified the milestones: Backlog, 2.9.4, 2.9.6 May 8, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants