Skip to content

Commit 05f2669

Browse files
authored
Merge pull request #694 from santoshilimi/DP-1352
#Dp-1352 fix: fixed the description issue programs api
2 parents 149e2e6 + d78df33 commit 05f2669

File tree

1 file changed

+112
-2
lines changed

1 file changed

+112
-2
lines changed

apis/programsapi/program.yaml

Lines changed: 112 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ openapi: 3.0.0
22
info:
33
title: Program Api's
44
termsOfService: "https://github.com/project-sunbird/sunbird-commons/blob/master/LICENSE"
5-
description: These are the API used to do all the operations about program like creating, updating and some more operations.
5+
description: Program construct enable to contribution program on sunbird for content creation and content contribution by individual and organisation.
66

77
contact:
88
@@ -1233,7 +1233,35 @@ paths:
12331233
responses:
12341234
200:
12351235
description: "Successful Unlist-Publish Program Content"
1236-
headers: {}
1236+
content:
1237+
application/json; charset=utf-8:
1238+
schema:
1239+
$ref: '#/components/schemas/resultProgram'
1240+
example:
1241+
id: api.program.publish
1242+
ts: 2021-01-12T10:57:24.721Z
1243+
params:
1244+
resmsgid: f3e64611-54c4-11eb-8795-e372ee0a4d37
1245+
msgid: f3e64610-54c4-11eb-8795-e372ee0a4d37
1246+
status: successful
1247+
err:
1248+
errmsg:
1249+
responseCode: OK
1250+
result:
1251+
program_id: d2f35e20-54c4-11eb-8795-e372ee0a4d37
1252+
afterPublishResponse:
1253+
nomination:
1254+
error:
1255+
result:
1256+
program_id: d2f35e20-54c4-11eb-8795-e372ee0a4d37
1257+
user_id: c5bbabfc-7f2b-4d2e-bdc4-64b0db810817
1258+
organisation_id: 32625405-bc59-4622-89bb-d06934d690ef
1259+
status: Approved
1260+
content_types:
1261+
- Course Assessment
1262+
collection_ids:
1263+
- do_21319279857165107214382
1264+
userMapping: {}
12371265
400:
12381266
description: Unlist-Publish Bad Request
12391267
content:
@@ -7988,6 +8016,88 @@ components:
79888016
err: ERR_PUBLISH_PROGRAM_DATA
79898017
errmsg: Required fields while publishing program data are missing
79908018

8019+
resultProgram:
8020+
title: This represents the publish program response
8021+
description: This represents the publish program response
8022+
required:
8023+
- id
8024+
- ts
8025+
- params
8026+
- responseCode
8027+
- result
8028+
type: object
8029+
properties:
8030+
id:
8031+
description: Represents the api id
8032+
type: string
8033+
ver:
8034+
description: Represents the api version
8035+
type: string
8036+
ts:
8037+
description: Represents the EPOCH epoch time in milliseconds
8038+
type: integer
8039+
format: int64
8040+
params:
8041+
$ref: '#/components/schemas/ProgramParams'
8042+
responseCode:
8043+
type: string
8044+
description: Represents the response code
8045+
result:
8046+
$ref: '#/components/schemas/PublishResult'
8047+
example:
8048+
id: api.program.publish
8049+
ts: 2021-01-12T10:57:24.721Z
8050+
params:
8051+
resmsgid: f3e64611-54c4-11eb-8795-e372ee0a4d37
8052+
msgid: f3e64610-54c4-11eb-8795-e372ee0a4d37
8053+
status: successful
8054+
err:
8055+
errmsg:
8056+
responseCode: OK
8057+
result:
8058+
program_id: d2f35e20-54c4-11eb-8795-e372ee0a4d37
8059+
afterPublishResponse:
8060+
nomination:
8061+
error:
8062+
result:
8063+
program_id: d2f35e20-54c4-11eb-8795-e372ee0a4d37
8064+
user_id: c5bbabfc-7f2b-4d2e-bdc4-64b0db810817
8065+
organisation_id: 32625405-bc59-4622-89bb-d06934d690ef
8066+
status: Approved
8067+
content_types:
8068+
- Course Assessment
8069+
collection_ids:
8070+
- do_21319279857165107214382
8071+
userMapping: {}
8072+
PublishResult:
8073+
title: Result
8074+
description: This represents publish response
8075+
required:
8076+
- program_id
8077+
- afterPublishResponse
8078+
type: object
8079+
properties:
8080+
program_id:
8081+
type: string
8082+
description: This represents the unique program id
8083+
afterPublishResponse:
8084+
$ref: '#/components/schemas/AfterPublishResponse'
8085+
example:
8086+
program_id: d2f35e20-54c4-11eb-8795-e372ee0a4d37
8087+
afterPublishResponse:
8088+
nomination:
8089+
error:
8090+
result:
8091+
program_id: d2f35e20-54c4-11eb-8795-e372ee0a4d37
8092+
user_id: c5bbabfc-7f2b-4d2e-bdc4-64b0db810817
8093+
organisation_id: 32625405-bc59-4622-89bb-d06934d690ef
8094+
status: Approved
8095+
content_types:
8096+
- Course Assessment
8097+
collection_ids:
8098+
- do_21319279857165107214382
8099+
userMapping: {}
8100+
79918101
tags:
79928102
- name: Program CRUD
79938103
- name: Report

0 commit comments

Comments
 (0)