175 строки
5.0 KiB
JSON
175 строки
5.0 KiB
JSON
{
|
|
"basePath": "/",
|
|
"consumes": [],
|
|
"definitions": {},
|
|
"host": "smarp.smarpshare.com",
|
|
"info": {
|
|
"description": "Smarp is a mobile-first employee communication platform to drive alignment, productivity and champion your brand. Connect to Smarp to manage your posts.",
|
|
"title": "Smarp",
|
|
"version": "1.0",
|
|
"x-ms-api-annotation": {
|
|
"status": "Preview"
|
|
}
|
|
},
|
|
"parameters": {},
|
|
"paths": {
|
|
"/publicapi/channel": {
|
|
"get": {
|
|
"description": "Retrieve channel list for creating a new post",
|
|
"operationId": "SmarpRetrieveChannelList",
|
|
"parameters": [
|
|
{
|
|
"default": "application/json",
|
|
"in": "header",
|
|
"name": "Accept",
|
|
"required": true,
|
|
"type": "string",
|
|
"x-ms-visibility": "internal"
|
|
}
|
|
],
|
|
"responses": {
|
|
"default": {
|
|
"description": "default",
|
|
"schema": {
|
|
"items": {
|
|
"properties": {
|
|
"_id": {
|
|
"description": "_id",
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"description": "name",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"type": "array"
|
|
}
|
|
}
|
|
},
|
|
"summary": "Retrieve Channel List",
|
|
"x-ms-visibility": "important"
|
|
}
|
|
},
|
|
"/publicapi/post": {
|
|
"post": {
|
|
"description": "Create a post when an item is created for your list",
|
|
"operationId": "SmarpCreatePost",
|
|
"parameters": [
|
|
{
|
|
"default": "application/json",
|
|
"in": "header",
|
|
"name": "Content-Type",
|
|
"required": true,
|
|
"type": "string",
|
|
"x-ms-visibility": "internal"
|
|
},
|
|
{
|
|
"default": "application/json",
|
|
"in": "header",
|
|
"name": "Accept",
|
|
"required": true,
|
|
"type": "string",
|
|
"x-ms-visibility": "internal"
|
|
},
|
|
{
|
|
"in": "body",
|
|
"name": "body",
|
|
"required": true,
|
|
"schema": {
|
|
"properties": {
|
|
"body": {
|
|
"description": "body",
|
|
"title": "Post Body",
|
|
"type": "string",
|
|
"x-ms-visibility": "important"
|
|
},
|
|
"channelList": {
|
|
"description": "channelList",
|
|
"items": {
|
|
"title": "Post Channel List",
|
|
"type": "string",
|
|
"x-ms-dynamic-values": {
|
|
"operationId": "SmarpRetrieveChannelList",
|
|
"parameters": {
|
|
"Accept": "application/json"
|
|
},
|
|
"value-path": "_id",
|
|
"value-title": "name"
|
|
},
|
|
"x-ms-visibility": "important"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"imageUrl": {
|
|
"description": "imageUrl",
|
|
"type": "string"
|
|
},
|
|
"proposed": {
|
|
"default": true,
|
|
"description": "proposed = true; published = false",
|
|
"title": "Post status",
|
|
"type": "boolean",
|
|
"x-ms-visibility": "important"
|
|
},
|
|
"shareable": {
|
|
"default": true,
|
|
"description": "shareable = true; internal = false",
|
|
"title": "Post Shareable Status",
|
|
"type": "boolean",
|
|
"x-ms-visibility": "important"
|
|
},
|
|
"title": {
|
|
"description": "title",
|
|
"type": "string"
|
|
},
|
|
"url": {
|
|
"description": "url",
|
|
"title": "Post URL",
|
|
"type": "string",
|
|
"x-ms-visibility": "important"
|
|
}
|
|
},
|
|
"required": [
|
|
"channelList"
|
|
],
|
|
"type": "object",
|
|
"x-ms-visibility": "important"
|
|
},
|
|
"x-ms-visibility": "important"
|
|
}
|
|
],
|
|
"responses": {
|
|
"default": {
|
|
"description": "default",
|
|
"schema": {}
|
|
}
|
|
},
|
|
"summary": "Create Post",
|
|
"x-ms-visibility": "important"
|
|
}
|
|
}
|
|
},
|
|
"produces": [],
|
|
"responses": {},
|
|
"schemes": [
|
|
"https"
|
|
],
|
|
"security": [
|
|
{
|
|
"oauth2_auth": []
|
|
}
|
|
],
|
|
"securityDefinitions": {
|
|
"oauth2_auth": {
|
|
"authorizationUrl": "https://login.smarpshare.com/oauth2/authorize",
|
|
"flow": "accessCode",
|
|
"scopes": {},
|
|
"tokenUrl": "https://login.smarpshare.com/oauth2/token",
|
|
"type": "oauth2"
|
|
}
|
|
},
|
|
"swagger": "2.0",
|
|
"tags": []
|
|
} |