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

Desired JSON data model #4

Open
kyyberi opened this issue Mar 23, 2017 · 3 comments
Open

Desired JSON data model #4

kyyberi opened this issue Mar 23, 2017 · 3 comments

Comments

@kyyberi
Copy link

kyyberi commented Mar 23, 2017

What is the desired data model coming out from harvesting so that it's easily used in reading the content in when using Catalog REST API POST method?

@NNN might know something from code level.

@kyyberi
Copy link
Author

kyyberi commented Mar 24, 2017

Example JSON configuration for API in apinf.io, which does not fit in all situations.

{
	"_id": "9nuJDa2vLQNaxmJQh",
	"latestMonitoringStatusCode": "-1",
	"name": "Ampersand test",
	"description": "test",
	"url": "https://api.apinf.io",
	"lifecycleStatus": "design",
	"managerIds": [
		"gYwfyAcuKxQ9udgSt"
	],
	"authorizedUserIds": [],
	"created_at": "2017-02-27T12:48:57.148Z",
	"bookmarkCount": 1,
	"isPublic": true,
	"updated_at": "2017-03-24T01:05:09.405Z",
	"submit_methods": [
		"get",
		"post",
		"delete",
		"put"
	],
	"documentationFileId": "2a1822480ff90cdc31600561"
}

@kyyberi
Copy link
Author

kyyberi commented Mar 24, 2017

Perhaps something like this.

{
	"_id": "null", (default is null)
	"latestMonitoringStatusCode": "0", (this is default)
	"name": "Ampersand test", (API name)
        "organizationName":"name of the organization",
	"description": "test", (Description field, around 200 chars)
	"url": "https://api.apinf.io", (API root)
        "specFile": { 
              "url":"Swagger file url", (default is null)
              "type":"swagger"
         },
	"lifecycleStatus": "production", (default is 'production')
	"managerIds": [], (default is empty array)
	"authorizedUserIds": [], (default is empty array)
	"created_at": "2017-02-27T12:48:57.148Z", (when created from harvester point of view)
	"bookmarkCount": 0, (default is 0)
	"isPublic": true, (default is true)
	"updated_at": "2017-03-24T01:05:09.405Z", (when updated from harvester point of view)
	"submit_methods": [], (default is empty array)
	"documentationFileId": "2a1822480ff90cdc31600561" (default is null)
}

@kyyberi
Copy link
Author

kyyberi commented Mar 24, 2017

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

1 participant