openapi.yaml 52 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513
  1. # Generated with protoc-gen-openapi
  2. # https://github.com/google/gnostic/tree/master/cmd/protoc-gen-openapi
  3. openapi: 3.0.3
  4. info:
  5. title: ""
  6. version: 0.0.1
  7. paths:
  8. /apis/v2/messagectx/message/load:
  9. get:
  10. tags:
  11. - Message
  12. description: 加载消息
  13. operationId: Message_Load
  14. responses:
  15. "200":
  16. description: OK
  17. content:
  18. application/json:
  19. schema:
  20. $ref: '#/components/schemas/api.msg.v2.LoadResponse'
  21. /apis/v2/messagectx/message/process:
  22. post:
  23. tags:
  24. - Message
  25. description: 处理消息
  26. operationId: Message_Process
  27. requestBody:
  28. content:
  29. application/json:
  30. schema:
  31. $ref: '#/components/schemas/api.msg.v2.ProcessRequest'
  32. required: true
  33. responses:
  34. "200":
  35. description: OK
  36. content:
  37. application/json:
  38. schema:
  39. $ref: '#/components/schemas/api.msg.v2.ProcessResponse'
  40. /apis/v2/messagectx/publish/registration:
  41. post:
  42. tags:
  43. - PublishRegistration
  44. description: 订阅推送
  45. operationId: PublishRegistration_Subscribe
  46. requestBody:
  47. content:
  48. application/json:
  49. schema:
  50. $ref: '#/components/schemas/api.push.v2.RegistrationRequest'
  51. required: true
  52. responses:
  53. "200":
  54. description: OK
  55. content:
  56. application/json:
  57. schema:
  58. $ref: '#/components/schemas/api.push.v2.RegistrationResponse'
  59. delete:
  60. tags:
  61. - PublishRegistration
  62. description: 取消订阅推送
  63. operationId: PublishRegistration_Unsubscribe
  64. parameters:
  65. - name: deviceSystem
  66. in: query
  67. description: 设备系统
  68. schema:
  69. type: integer
  70. format: enum
  71. - name: deviceSystemVersion
  72. in: query
  73. description: 设备系统版本
  74. schema:
  75. type: string
  76. - name: deviceManufacturer
  77. in: query
  78. description: 设备厂商
  79. schema:
  80. type: string
  81. - name: deviceModel
  82. in: query
  83. description: 设备型号
  84. schema:
  85. type: string
  86. - name: userId
  87. in: query
  88. description: 推送用户 ID
  89. schema:
  90. type: string
  91. - name: registrantPlatformType
  92. in: query
  93. description: 推送平台
  94. schema:
  95. type: integer
  96. format: enum
  97. - name: regId
  98. in: query
  99. description: |-
  100. 推送 regId
  101. 已知的 APNs 是一个 Token 类型的格式,其他的平台基本上都是ID 的形式
  102. IOS 的 APNs 有使用这个字段,推送 ID 字段是必须的
  103. schema:
  104. type: string
  105. responses:
  106. "200":
  107. description: OK
  108. content:
  109. application/json:
  110. schema:
  111. $ref: '#/components/schemas/api.push.v2.RegistrationResponse'
  112. /apis/v2/user/alarm-clock/delete:
  113. get:
  114. tags:
  115. - AlarmClock
  116. description: 删除闹钟
  117. operationId: AlarmClock_DeleteAlarmClock
  118. parameters:
  119. - name: id
  120. in: query
  121. description: 闹钟ID
  122. schema:
  123. type: string
  124. responses:
  125. "200":
  126. description: OK
  127. content:
  128. application/json:
  129. schema:
  130. $ref: '#/components/schemas/api.user.v2.DeleteAlarmClockResponse'
  131. /apis/v2/userctx/user/alarm-clock/create:
  132. post:
  133. tags:
  134. - AlarmClock
  135. description: 创建闹钟
  136. operationId: AlarmClock_CreateAlarmClock
  137. requestBody:
  138. content:
  139. application/json:
  140. schema:
  141. $ref: '#/components/schemas/api.user.v2.CreateAlarmClockRequest'
  142. required: true
  143. responses:
  144. "200":
  145. description: OK
  146. content:
  147. application/json:
  148. schema:
  149. $ref: '#/components/schemas/api.user.v2.CreateAlarmClockResponse'
  150. /apis/v2/userctx/user/alarm-clock/getall:
  151. get:
  152. tags:
  153. - AlarmClock
  154. description: 获取闹钟
  155. operationId: AlarmClock_GetAlarmClock
  156. parameters:
  157. - name: cid
  158. in: query
  159. schema:
  160. type: string
  161. responses:
  162. "200":
  163. description: OK
  164. content:
  165. application/json:
  166. schema:
  167. $ref: '#/components/schemas/api.user.v2.GetAlarmClockResponse'
  168. /apis/v2/userctx/user/alarm-clock/update:
  169. post:
  170. tags:
  171. - AlarmClock
  172. description: 修改闹钟
  173. operationId: AlarmClock_UpdateAlarmClock
  174. requestBody:
  175. content:
  176. application/json:
  177. schema:
  178. $ref: '#/components/schemas/api.user.v2.UpdateAlarmClockRequest'
  179. required: true
  180. responses:
  181. "200":
  182. description: OK
  183. content:
  184. application/json:
  185. schema:
  186. $ref: '#/components/schemas/api.user.v2.UpdateAlarmClockResponse'
  187. /apis/v2/userctx/user/child/contacts/create:
  188. post:
  189. tags:
  190. - Contacts
  191. description: 创建联系人
  192. operationId: Contacts_CreateContactPerson
  193. requestBody:
  194. content:
  195. application/json:
  196. schema:
  197. $ref: '#/components/schemas/api.user.v2.CreateContactPersonRequest'
  198. required: true
  199. responses:
  200. "200":
  201. description: OK
  202. content:
  203. application/json:
  204. schema:
  205. $ref: '#/components/schemas/api.user.v2.CreateContactPersonResponse'
  206. /apis/v2/userctx/user/child/contacts/delete:
  207. get:
  208. tags:
  209. - Contacts
  210. description: 删除联系人
  211. operationId: Contacts_DeleteContactPerson
  212. parameters:
  213. - name: id
  214. in: query
  215. schema:
  216. type: string
  217. responses:
  218. "200":
  219. description: OK
  220. content:
  221. application/json:
  222. schema:
  223. $ref: '#/components/schemas/api.user.v2.DeleteContactPersonResponse'
  224. /apis/v2/userctx/user/child/contacts/firend/add:
  225. post:
  226. tags:
  227. - Contacts
  228. description: 添加好友
  229. operationId: Contacts_AddFirend
  230. requestBody:
  231. content:
  232. application/json:
  233. schema:
  234. $ref: '#/components/schemas/api.user.v2.AddFirendRequest'
  235. required: true
  236. responses:
  237. "200":
  238. description: OK
  239. content:
  240. application/json:
  241. schema:
  242. $ref: '#/components/schemas/api.user.v2.AddFirendResponse'
  243. /apis/v2/userctx/user/child/contacts/firend/delete:
  244. delete:
  245. tags:
  246. - Contacts
  247. description: 删除好友
  248. operationId: Contacts_DeleteFirend
  249. parameters:
  250. - name: id
  251. in: query
  252. schema:
  253. type: string
  254. responses:
  255. "200":
  256. description: OK
  257. content:
  258. application/json:
  259. schema:
  260. $ref: '#/components/schemas/api.user.v2.DeleteFirendResponse'
  261. /apis/v2/userctx/user/child/contacts/firend/generate-code:
  262. post:
  263. tags:
  264. - Contacts
  265. description: 生成好友码
  266. operationId: Contacts_GenerateFirendCode
  267. requestBody:
  268. content:
  269. application/json:
  270. schema:
  271. $ref: '#/components/schemas/api.user.v2.GenerateFirendCodeRequest'
  272. required: true
  273. responses:
  274. "200":
  275. description: OK
  276. content:
  277. application/json:
  278. schema:
  279. $ref: '#/components/schemas/api.user.v2.GenerateFirendCodeResponse'
  280. /apis/v2/userctx/user/child/contacts/firend/get:
  281. get:
  282. tags:
  283. - Contacts
  284. description: 好友列表
  285. operationId: Contacts_GetFirend
  286. parameters:
  287. - name: ticket
  288. in: query
  289. schema:
  290. type: string
  291. responses:
  292. "200":
  293. description: OK
  294. content:
  295. application/json:
  296. schema:
  297. $ref: '#/components/schemas/api.user.v2.GetFirendResponse'
  298. /apis/v2/userctx/user/child/contacts/get:
  299. get:
  300. tags:
  301. - Contacts
  302. description: 获取联系人
  303. operationId: Contacts_GetContactPerson
  304. parameters:
  305. - name: cid
  306. in: query
  307. schema:
  308. type: string
  309. responses:
  310. "200":
  311. description: OK
  312. content:
  313. application/json:
  314. schema:
  315. $ref: '#/components/schemas/api.user.v2.GetContactPersonResponse'
  316. /apis/v2/userctx/user/child/contacts/update:
  317. post:
  318. tags:
  319. - Contacts
  320. description: 更新联系人
  321. operationId: Contacts_UpdateContactPerson
  322. requestBody:
  323. content:
  324. application/json:
  325. schema:
  326. $ref: '#/components/schemas/api.user.v2.UpdateContactPersonRequest'
  327. required: true
  328. responses:
  329. "200":
  330. description: OK
  331. content:
  332. application/json:
  333. schema:
  334. $ref: '#/components/schemas/api.user.v2.UpdateContactPersonResponse'
  335. /apis/v2/userctx/user/child/contacts/wristwatch/get:
  336. get:
  337. tags:
  338. - Contacts
  339. description: 手表获取联系人
  340. operationId: Contacts_GetWristwatchContactPerson
  341. parameters:
  342. - name: ticket
  343. in: query
  344. schema:
  345. type: string
  346. responses:
  347. "200":
  348. description: OK
  349. content:
  350. application/json:
  351. schema:
  352. $ref: '#/components/schemas/api.user.v2.GetWristwatchContactPersonResponse'
  353. /apis/v2/userctx/user/child/create:
  354. post:
  355. tags:
  356. - Child
  357. description: 创建新的小孩
  358. operationId: Child_CreateChild
  359. requestBody:
  360. content:
  361. application/json:
  362. schema:
  363. $ref: '#/components/schemas/api.user.v2.CreateChildRequest'
  364. required: true
  365. responses:
  366. "200":
  367. description: OK
  368. content:
  369. application/json:
  370. schema:
  371. $ref: '#/components/schemas/api.user.v2.CreateChildResponse'
  372. /apis/v2/userctx/user/child/delete:
  373. get:
  374. tags:
  375. - Child
  376. description: 删除小孩
  377. operationId: Child_DeleteChild
  378. parameters:
  379. - name: cid
  380. in: query
  381. schema:
  382. type: string
  383. responses:
  384. "200":
  385. description: OK
  386. content:
  387. application/json:
  388. schema:
  389. $ref: '#/components/schemas/api.user.v2.DeleteChildResponse'
  390. /apis/v2/userctx/user/child/device/bind:
  391. post:
  392. tags:
  393. - Device
  394. description: 绑定设备
  395. operationId: Device_DeviceBind
  396. requestBody:
  397. content:
  398. application/json:
  399. schema:
  400. $ref: '#/components/schemas/api.user.v2.DeviceBindRequest'
  401. required: true
  402. responses:
  403. "200":
  404. description: OK
  405. content:
  406. application/json:
  407. schema:
  408. $ref: '#/components/schemas/api.user.v2.DeviceBindResponse'
  409. /apis/v2/userctx/user/child/device/binding:
  410. get:
  411. tags:
  412. - Device
  413. description: 获取设备绑定状态
  414. operationId: Device_DeviceBinding
  415. parameters:
  416. - name: ticket
  417. in: query
  418. schema:
  419. type: string
  420. responses:
  421. "200":
  422. description: OK
  423. content:
  424. application/json:
  425. schema:
  426. $ref: '#/components/schemas/api.user.v2.DeviceBindingResponse'
  427. /apis/v2/userctx/user/child/device/exchange:
  428. get:
  429. tags:
  430. - Device
  431. description: 交换三码
  432. operationId: Device_DeviceExchange
  433. parameters:
  434. - name: hc
  435. in: query
  436. schema:
  437. type: string
  438. responses:
  439. "200":
  440. description: OK
  441. content:
  442. application/json:
  443. schema:
  444. $ref: '#/components/schemas/api.user.v2.DeviceExchangeResponse'
  445. /apis/v2/userctx/user/child/device/unbind:
  446. post:
  447. tags:
  448. - Device
  449. description: 解绑设备
  450. operationId: Device_DeviceUnbind
  451. requestBody:
  452. content:
  453. application/json:
  454. schema:
  455. $ref: '#/components/schemas/api.user.v2.DeviceUnbindRequest'
  456. required: true
  457. responses:
  458. "200":
  459. description: OK
  460. content:
  461. application/json:
  462. schema:
  463. $ref: '#/components/schemas/api.user.v2.DeviceUnbindResponse'
  464. /apis/v2/userctx/user/child/get:
  465. get:
  466. tags:
  467. - Child
  468. description: 获取用户自己的小孩列表
  469. operationId: Child_GetChild
  470. responses:
  471. "200":
  472. description: OK
  473. content:
  474. application/json:
  475. schema:
  476. $ref: '#/components/schemas/api.user.v2.GetChildResponse'
  477. /apis/v2/userctx/user/child/school-disable/create:
  478. post:
  479. tags:
  480. - SchoolDisable
  481. description: 创建上课禁用
  482. operationId: SchoolDisable_CreateSchoolDisable
  483. requestBody:
  484. content:
  485. application/json:
  486. schema:
  487. $ref: '#/components/schemas/api.user.v2.CreateSchoolDisableRequest'
  488. required: true
  489. responses:
  490. "200":
  491. description: OK
  492. content:
  493. application/json:
  494. schema:
  495. $ref: '#/components/schemas/api.user.v2.CreateSchoolDisableResponse'
  496. /apis/v2/userctx/user/child/school-disable/delete:
  497. get:
  498. tags:
  499. - SchoolDisable
  500. description: 删除上课禁用
  501. operationId: SchoolDisable_DeleteSchoolDisable
  502. parameters:
  503. - name: id
  504. in: query
  505. schema:
  506. type: string
  507. responses:
  508. "200":
  509. description: OK
  510. content:
  511. application/json:
  512. schema:
  513. $ref: '#/components/schemas/api.user.v2.DeleteSchoolDisableResponse'
  514. /apis/v2/userctx/user/child/school-disable/get:
  515. get:
  516. tags:
  517. - SchoolDisable
  518. description: 获取上课禁用
  519. operationId: SchoolDisable_GetSchoolDisable
  520. parameters:
  521. - name: cid
  522. in: query
  523. schema:
  524. type: string
  525. responses:
  526. "200":
  527. description: OK
  528. content:
  529. application/json:
  530. schema:
  531. $ref: '#/components/schemas/api.user.v2.GetSchoolDisableResponse'
  532. /apis/v2/userctx/user/child/school-disable/update:
  533. post:
  534. tags:
  535. - SchoolDisable
  536. description: 更新上课禁用
  537. operationId: SchoolDisable_UpdateSchoolDisable
  538. requestBody:
  539. content:
  540. application/json:
  541. schema:
  542. $ref: '#/components/schemas/api.user.v2.UpdateSchoolDisableRequest'
  543. required: true
  544. responses:
  545. "200":
  546. description: OK
  547. content:
  548. application/json:
  549. schema:
  550. $ref: '#/components/schemas/api.user.v2.UpdateSchoolDisableResponse'
  551. /apis/v2/userctx/user/child/school-disable/wristwatch/get:
  552. get:
  553. tags:
  554. - SchoolDisable
  555. description: 手表获取上课禁用
  556. operationId: SchoolDisable_GetWristwatchSchoolDisable
  557. parameters:
  558. - name: ticket
  559. in: query
  560. schema:
  561. type: string
  562. responses:
  563. "200":
  564. description: OK
  565. content:
  566. application/json:
  567. schema:
  568. $ref: '#/components/schemas/api.user.v2.GetWristwatchSchoolDisableResponse'
  569. /apis/v2/userctx/user/child/update:
  570. post:
  571. tags:
  572. - Child
  573. description: 更新小孩信息
  574. operationId: Child_UpdateChild
  575. requestBody:
  576. content:
  577. application/json:
  578. schema:
  579. $ref: '#/components/schemas/api.user.v2.UpdateChildRequest'
  580. required: true
  581. responses:
  582. "200":
  583. description: OK
  584. content:
  585. application/json:
  586. schema:
  587. $ref: '#/components/schemas/api.user.v2.UpdateChildResponse'
  588. /apis/v2/userctx/user/reset-password:
  589. post:
  590. tags:
  591. - User
  592. description: 重设密码
  593. operationId: User_ResetPassword
  594. requestBody:
  595. content:
  596. application/json:
  597. schema:
  598. $ref: '#/components/schemas/api.user.v2.ResetPasswordRequest'
  599. required: true
  600. responses:
  601. "200":
  602. description: OK
  603. content:
  604. application/json:
  605. schema:
  606. $ref: '#/components/schemas/api.user.v2.ResetPasswordResponse'
  607. /apis/v2/userctx/user/retrieve-password:
  608. post:
  609. tags:
  610. - User
  611. description: 找回密码
  612. operationId: User_RetrievePassword
  613. requestBody:
  614. content:
  615. application/json:
  616. schema:
  617. $ref: '#/components/schemas/api.user.v2.RetrievePasswordRequest'
  618. required: true
  619. responses:
  620. "200":
  621. description: OK
  622. content:
  623. application/json:
  624. schema:
  625. $ref: '#/components/schemas/api.user.v2.RetrievePasswordResponse'
  626. /apis/v2/userctx/user/sign-in:
  627. post:
  628. tags:
  629. - User
  630. description: 登录
  631. operationId: User_SignIn
  632. requestBody:
  633. content:
  634. application/json:
  635. schema:
  636. $ref: '#/components/schemas/api.user.v2.SignInRequest'
  637. required: true
  638. responses:
  639. "200":
  640. description: OK
  641. content:
  642. application/json:
  643. schema:
  644. $ref: '#/components/schemas/api.user.v2.SignInResponse'
  645. /apis/v2/userctx/user/sign-up:
  646. post:
  647. tags:
  648. - User
  649. description: 注册
  650. operationId: User_SignUp
  651. requestBody:
  652. content:
  653. application/json:
  654. schema:
  655. $ref: '#/components/schemas/api.user.v2.SignUpRequest'
  656. required: true
  657. responses:
  658. "200":
  659. description: OK
  660. content:
  661. application/json:
  662. schema:
  663. $ref: '#/components/schemas/api.user.v2.SignUpResponse'
  664. /apis/v2/userctx/user/sms-code:
  665. post:
  666. tags:
  667. - User
  668. description: 短信验证码
  669. operationId: User_SMSCode
  670. requestBody:
  671. content:
  672. application/json:
  673. schema:
  674. $ref: '#/components/schemas/api.user.v2.SMSCodeRequest'
  675. required: true
  676. responses:
  677. "200":
  678. description: OK
  679. content:
  680. application/json:
  681. schema:
  682. $ref: '#/components/schemas/api.user.v2.SMSCodeResponse'
  683. /apis/v2/userctx/user/unregister:
  684. post:
  685. tags:
  686. - User
  687. description: 注销
  688. operationId: User_Unregister
  689. requestBody:
  690. content:
  691. application/json:
  692. schema:
  693. $ref: '#/components/schemas/api.user.v2.UnregisterRequest'
  694. required: true
  695. responses:
  696. "200":
  697. description: OK
  698. content:
  699. application/json:
  700. schema:
  701. $ref: '#/components/schemas/api.user.v2.UnregisterResponse'
  702. /apis/v2/userctx/user/wristwatch/alarm-clock/get:
  703. get:
  704. tags:
  705. - AlarmClock
  706. description: 手表获取闹钟
  707. operationId: AlarmClock_GetWristwatchAlarmClock
  708. parameters:
  709. - name: ticket
  710. in: query
  711. schema:
  712. type: string
  713. responses:
  714. "200":
  715. description: OK
  716. content:
  717. application/json:
  718. schema:
  719. $ref: '#/components/schemas/api.user.v2.GetWristwatchAlarmClockResponse'
  720. components:
  721. schemas:
  722. api.msg.v2.LoadResponse:
  723. type: object
  724. properties: {}
  725. api.msg.v2.ProcessRequest:
  726. type: object
  727. properties:
  728. messageType:
  729. type: integer
  730. description: 消息类型
  731. format: int32
  732. ackId:
  733. type: integer
  734. description: ack id
  735. format: int32
  736. content:
  737. type: string
  738. description: 消息内容
  739. format: bytes
  740. msgId:
  741. type: string
  742. description: 消息id
  743. status:
  744. type: integer
  745. description: 消息状态
  746. format: int32
  747. isGroup:
  748. type: boolean
  749. description: 是否是群消息
  750. recvId:
  751. type: string
  752. description: 接收者id
  753. SendId:
  754. type: string
  755. description: 发送者id
  756. api.msg.v2.ProcessResponse:
  757. type: object
  758. properties:
  759. msgId:
  760. type: string
  761. api.push.v2.RegistrationRequest:
  762. type: object
  763. properties:
  764. deviceSystem:
  765. type: integer
  766. description: 设备系统
  767. format: enum
  768. deviceSystemVersion:
  769. type: string
  770. description: 设备系统版本
  771. deviceManufacturer:
  772. type: string
  773. description: 设备厂商
  774. deviceModel:
  775. type: string
  776. description: 设备型号
  777. userId:
  778. type: string
  779. description: 推送用户 ID
  780. registrantPlatformType:
  781. type: integer
  782. description: 推送平台
  783. format: enum
  784. regId:
  785. type: string
  786. description: |-
  787. 推送 regId
  788. 已知的 APNs 是一个 Token 类型的格式,其他的平台基本上都是ID 的形式
  789. IOS 的 APNs 有使用这个字段,推送 ID 字段是必须的
  790. api.push.v2.RegistrationResponse:
  791. type: object
  792. properties: {}
  793. api.user.v2.AddFirendRequest:
  794. type: object
  795. properties:
  796. code:
  797. type: string
  798. description: 添加好友 Request
  799. api.user.v2.AddFirendResponse:
  800. type: object
  801. properties: {}
  802. description: 添加好友 Response
  803. api.user.v2.CreateAlarmClockRequest:
  804. type: object
  805. properties:
  806. cid:
  807. type: string
  808. description: 小孩ID
  809. label:
  810. type: string
  811. description: 闹钟标签
  812. repeats:
  813. type: string
  814. description: '重复天 eg: 1000000 周一开启 1111100 工作日开启'
  815. time:
  816. type: string
  817. description: 'Time 闹钟时间 格式: HH:mm'
  818. onceTime:
  819. type: string
  820. description: 仅一次时间戳
  821. status:
  822. type: boolean
  823. description: 是否开启
  824. description: 创建闹钟 Request
  825. api.user.v2.CreateAlarmClockResponse:
  826. type: object
  827. properties: {}
  828. description: 创建闹钟 Response
  829. api.user.v2.CreateChildRequest:
  830. type: object
  831. properties:
  832. name:
  833. type: string
  834. description: 小孩姓名
  835. phoneNumber:
  836. type: string
  837. description: 小孩电话
  838. areaCode:
  839. type: string
  840. description: 小孩电话区号
  841. avatar:
  842. type: string
  843. description: 小孩头像
  844. birthday:
  845. type: string
  846. description: 小孩生日
  847. appellation:
  848. type: string
  849. description: 小孩对自己的称谓
  850. gender:
  851. type: integer
  852. description: 小孩性别
  853. format: enum
  854. weight:
  855. type: integer
  856. description: 小孩体重
  857. format: int32
  858. height:
  859. type: integer
  860. description: 小孩身高
  861. format: int32
  862. api.user.v2.CreateChildResponse:
  863. type: object
  864. properties:
  865. cid:
  866. type: string
  867. api.user.v2.CreateContactPersonRequest:
  868. type: object
  869. properties:
  870. avatar:
  871. type: string
  872. phoneNumber:
  873. type: string
  874. areaCode:
  875. type: string
  876. appellation:
  877. type: string
  878. description: 小孩对自己的称谓
  879. role:
  880. type: integer
  881. format: enum
  882. cid:
  883. type: string
  884. description: 创建联系人 Request
  885. api.user.v2.CreateContactPersonResponse:
  886. type: object
  887. properties: {}
  888. description: 创建联系人 Response
  889. api.user.v2.CreateSchoolDisableRequest:
  890. type: object
  891. properties:
  892. cid:
  893. type: string
  894. repeats:
  895. type: string
  896. startTime:
  897. type: string
  898. endTime:
  899. type: string
  900. status:
  901. type: boolean
  902. description: 创建上课禁用 Request
  903. api.user.v2.CreateSchoolDisableResponse:
  904. type: object
  905. properties:
  906. id:
  907. type: string
  908. description: 创建上课禁用 Response
  909. api.user.v2.DeleteAlarmClockResponse:
  910. type: object
  911. properties: {}
  912. description: 删除闹钟 Response
  913. api.user.v2.DeleteChildResponse:
  914. type: object
  915. properties: {}
  916. api.user.v2.DeleteContactPersonResponse:
  917. type: object
  918. properties: {}
  919. description: 删除联系人 Response
  920. api.user.v2.DeleteFirendResponse:
  921. type: object
  922. properties: {}
  923. description: 删除好友 Response
  924. api.user.v2.DeleteSchoolDisableResponse:
  925. type: object
  926. properties: {}
  927. description: 删除上课禁用 Response
  928. api.user.v2.DeviceBindRequest:
  929. type: object
  930. properties:
  931. cid:
  932. type: string
  933. ticket:
  934. type: string
  935. description: 绑定设备 Request
  936. api.user.v2.DeviceBindResponse:
  937. type: object
  938. properties: {}
  939. description: 绑定设备 Response
  940. api.user.v2.DeviceBindingResponse:
  941. type: object
  942. properties:
  943. isBind:
  944. type: boolean
  945. description: 是否被绑定
  946. cid:
  947. type: string
  948. description: 被绑定的小孩ID
  949. token:
  950. type: string
  951. description: |-
  952. 设备的 accessToken
  953. 后续接口需要通过这个来进行交互
  954. weight:
  955. type: integer
  956. description: 体重
  957. format: int32
  958. height:
  959. type: integer
  960. description: 身高
  961. format: int32
  962. description: 获取设备绑定状态 Response
  963. api.user.v2.DeviceExchangeResponse:
  964. type: object
  965. properties:
  966. ticket:
  967. type: string
  968. description: |-
  969. ticket 用于生成设备绑定二维码使用
  970. 在连接 temp websocket 时也会用到
  971. aseKey:
  972. type: string
  973. hc:
  974. type: string
  975. activationTime:
  976. type: string
  977. description: 设备激活时间
  978. api.user.v2.DeviceUnbindRequest:
  979. type: object
  980. properties:
  981. cid:
  982. type: string
  983. ticket:
  984. type: string
  985. description: 解绑设备
  986. api.user.v2.DeviceUnbindResponse:
  987. type: object
  988. properties: {}
  989. description: 解绑设备
  990. api.user.v2.GenerateFirendCodeRequest:
  991. type: object
  992. properties:
  993. ticket:
  994. type: string
  995. description: 生成好友码 Request
  996. api.user.v2.GenerateFirendCodeResponse:
  997. type: object
  998. properties:
  999. code:
  1000. type: string
  1001. description: 生成好友码 Response
  1002. api.user.v2.GetAlarmClockResponse:
  1003. type: object
  1004. properties:
  1005. alarmClocks:
  1006. type: array
  1007. items:
  1008. $ref: '#/components/schemas/api.user.v2.GetAlarmClockResponse_AlarmClock'
  1009. description: 获取闹钟 Response
  1010. api.user.v2.GetAlarmClockResponse_AlarmClock:
  1011. type: object
  1012. properties:
  1013. cid:
  1014. type: string
  1015. label:
  1016. type: string
  1017. repeats:
  1018. type: string
  1019. time:
  1020. type: string
  1021. onceTime:
  1022. type: string
  1023. id:
  1024. type: string
  1025. status:
  1026. type: boolean
  1027. api.user.v2.GetChildResponse:
  1028. type: object
  1029. properties:
  1030. childList:
  1031. type: array
  1032. items:
  1033. $ref: '#/components/schemas/api.user.v2.GetChildResponse_Child'
  1034. api.user.v2.GetChildResponse_Child:
  1035. type: object
  1036. properties:
  1037. cid:
  1038. type: string
  1039. description: 小孩ID
  1040. stepCount:
  1041. type: integer
  1042. format: int32
  1043. name:
  1044. type: string
  1045. avatar:
  1046. type: string
  1047. device:
  1048. allOf:
  1049. - $ref: '#/components/schemas/api.user.v2.GetChildResponse_Device'
  1050. description: 绑定的设备
  1051. lastLocation:
  1052. allOf:
  1053. - $ref: '#/components/schemas/api.user.v2.GetChildResponse_Location'
  1054. description: 最后一次位置
  1055. api.user.v2.GetChildResponse_Device:
  1056. type: object
  1057. properties:
  1058. did:
  1059. type: string
  1060. battery:
  1061. type: integer
  1062. format: int32
  1063. signal:
  1064. type: integer
  1065. format: int32
  1066. signalMax:
  1067. type: integer
  1068. format: int32
  1069. ticket:
  1070. type: string
  1071. api.user.v2.GetChildResponse_Location:
  1072. type: object
  1073. properties:
  1074. latitude:
  1075. type: string
  1076. longitude:
  1077. type: string
  1078. positionTime:
  1079. type: string
  1080. radius:
  1081. type: integer
  1082. format: int32
  1083. pointType:
  1084. type: integer
  1085. format: enum
  1086. api.user.v2.GetContactPersonResponse:
  1087. type: object
  1088. properties:
  1089. persons:
  1090. type: array
  1091. items:
  1092. $ref: '#/components/schemas/api.user.v2.GetContactPersonResponse_Person'
  1093. description: 获取联系人 Response
  1094. api.user.v2.GetContactPersonResponse_Person:
  1095. type: object
  1096. properties:
  1097. id:
  1098. type: string
  1099. avatar:
  1100. type: string
  1101. phoneNumber:
  1102. type: string
  1103. areaCode:
  1104. type: string
  1105. appellation:
  1106. type: string
  1107. role:
  1108. type: integer
  1109. format: enum
  1110. api.user.v2.GetFirendResponse:
  1111. type: object
  1112. properties:
  1113. firends:
  1114. type: array
  1115. items:
  1116. $ref: '#/components/schemas/api.user.v2.GetFirendResponse_Firend'
  1117. description: 好友列表 Response
  1118. api.user.v2.GetFirendResponse_Firend:
  1119. type: object
  1120. properties:
  1121. id:
  1122. type: string
  1123. ticket:
  1124. type: string
  1125. name:
  1126. type: string
  1127. api.user.v2.GetSchoolDisableResponse:
  1128. type: object
  1129. properties:
  1130. schoolDisables:
  1131. type: array
  1132. items:
  1133. $ref: '#/components/schemas/api.user.v2.GetSchoolDisableResponse_SchoolDisable'
  1134. description: 获取上课禁用 Response
  1135. api.user.v2.GetSchoolDisableResponse_SchoolDisable:
  1136. type: object
  1137. properties:
  1138. cid:
  1139. type: string
  1140. repeats:
  1141. type: string
  1142. startTime:
  1143. type: string
  1144. endTime:
  1145. type: string
  1146. status:
  1147. type: boolean
  1148. id:
  1149. type: string
  1150. api.user.v2.GetWristwatchAlarmClockResponse:
  1151. type: object
  1152. properties:
  1153. alarmClocks:
  1154. type: array
  1155. items:
  1156. $ref: '#/components/schemas/api.user.v2.GetWristwatchAlarmClockResponse_AlarmClock'
  1157. description: 手表获取闹钟 Response
  1158. api.user.v2.GetWristwatchAlarmClockResponse_AlarmClock:
  1159. type: object
  1160. properties:
  1161. cid:
  1162. type: string
  1163. label:
  1164. type: string
  1165. repeats:
  1166. type: string
  1167. time:
  1168. type: string
  1169. onceTime:
  1170. type: string
  1171. id:
  1172. type: string
  1173. status:
  1174. type: boolean
  1175. api.user.v2.GetWristwatchContactPersonResponse:
  1176. type: object
  1177. properties:
  1178. persons:
  1179. type: array
  1180. items:
  1181. $ref: '#/components/schemas/api.user.v2.GetWristwatchContactPersonResponse_Person'
  1182. description: 手表获取联系人 Response
  1183. api.user.v2.GetWristwatchContactPersonResponse_Person:
  1184. type: object
  1185. properties:
  1186. id:
  1187. type: string
  1188. userId:
  1189. type: string
  1190. phoneNumber:
  1191. type: string
  1192. areaCode:
  1193. type: string
  1194. appellation:
  1195. type: string
  1196. role:
  1197. type: integer
  1198. format: enum
  1199. isChat:
  1200. type: boolean
  1201. isSos:
  1202. type: boolean
  1203. isAddedByWristwatch:
  1204. type: boolean
  1205. api.user.v2.GetWristwatchSchoolDisableResponse:
  1206. type: object
  1207. properties:
  1208. schoolDisables:
  1209. type: array
  1210. items:
  1211. $ref: '#/components/schemas/api.user.v2.GetWristwatchSchoolDisableResponse_SchoolDisable'
  1212. description: 手表获取上课禁用 Response
  1213. api.user.v2.GetWristwatchSchoolDisableResponse_SchoolDisable:
  1214. type: object
  1215. properties:
  1216. cid:
  1217. type: string
  1218. repeats:
  1219. type: string
  1220. startTime:
  1221. type: string
  1222. endTime:
  1223. type: string
  1224. status:
  1225. type: boolean
  1226. id:
  1227. type: string
  1228. api.user.v2.ResetPasswordRequest:
  1229. type: object
  1230. properties:
  1231. oldPassword:
  1232. type: string
  1233. description: 旧密码
  1234. newPassword:
  1235. type: string
  1236. description: 新密码
  1237. description: 重设密码 Request
  1238. api.user.v2.ResetPasswordResponse:
  1239. type: object
  1240. properties: {}
  1241. description: 重设密码 Response
  1242. api.user.v2.RetrievePasswordRequest:
  1243. type: object
  1244. properties:
  1245. email:
  1246. type: string
  1247. description: 邮箱
  1248. password:
  1249. type: string
  1250. description: 新密码
  1251. description: 找回密码 Request
  1252. api.user.v2.RetrievePasswordResponse:
  1253. type: object
  1254. properties: {}
  1255. description: 找回密码 Response
  1256. api.user.v2.SMSCodeRequest:
  1257. type: object
  1258. properties:
  1259. phone:
  1260. type: string
  1261. description: 手机号
  1262. areaCode:
  1263. type: string
  1264. description: 国家码
  1265. api.user.v2.SMSCodeResponse:
  1266. type: object
  1267. properties: {}
  1268. api.user.v2.SignInRequest:
  1269. type: object
  1270. properties:
  1271. phone:
  1272. type: string
  1273. description: 手机号
  1274. areaCode:
  1275. type: string
  1276. description: 国家码
  1277. password:
  1278. type: string
  1279. description: 密码
  1280. email:
  1281. type: string
  1282. description: 邮箱
  1283. captcha:
  1284. type: string
  1285. description: 验证码
  1286. description: 登录 Request
  1287. api.user.v2.SignInResponse:
  1288. type: object
  1289. properties:
  1290. token:
  1291. type: string
  1292. description: 当前登录的 AccessToken
  1293. uid:
  1294. type: string
  1295. description: 当前登录的用户
  1296. childList:
  1297. type: array
  1298. items:
  1299. $ref: '#/components/schemas/api.user.v2.SignInResponse_Child'
  1300. description: 绑定的小孩列表
  1301. description: 登录 Response
  1302. api.user.v2.SignInResponse_Child:
  1303. type: object
  1304. properties:
  1305. cid:
  1306. type: string
  1307. description: 小孩ID
  1308. stepCount:
  1309. type: integer
  1310. format: int32
  1311. name:
  1312. type: string
  1313. avatar:
  1314. type: string
  1315. device:
  1316. allOf:
  1317. - $ref: '#/components/schemas/api.user.v2.SignInResponse_Device'
  1318. description: 绑定的设备
  1319. lastLocation:
  1320. allOf:
  1321. - $ref: '#/components/schemas/api.user.v2.SignInResponse_Location'
  1322. description: 最后一次位置
  1323. api.user.v2.SignInResponse_Device:
  1324. type: object
  1325. properties:
  1326. did:
  1327. type: string
  1328. battery:
  1329. type: integer
  1330. format: int32
  1331. signal:
  1332. type: integer
  1333. format: int32
  1334. signalMax:
  1335. type: integer
  1336. format: int32
  1337. ticket:
  1338. type: string
  1339. api.user.v2.SignInResponse_Location:
  1340. type: object
  1341. properties:
  1342. latitude:
  1343. type: string
  1344. longitude:
  1345. type: string
  1346. positionTime:
  1347. type: string
  1348. radius:
  1349. type: integer
  1350. format: int32
  1351. pointType:
  1352. type: integer
  1353. format: enum
  1354. api.user.v2.SignUpRequest:
  1355. type: object
  1356. properties:
  1357. phone:
  1358. type: string
  1359. description: 手机号
  1360. areaCode:
  1361. type: string
  1362. description: 国家码
  1363. password:
  1364. type: string
  1365. description: 密码
  1366. email:
  1367. type: string
  1368. description: 邮箱
  1369. captcha:
  1370. type: string
  1371. description: 验证码
  1372. api.user.v2.SignUpResponse:
  1373. type: object
  1374. properties: {}
  1375. api.user.v2.UnregisterRequest:
  1376. type: object
  1377. properties:
  1378. password:
  1379. type: string
  1380. description: 密码
  1381. description: 注销账号 Request
  1382. api.user.v2.UnregisterResponse:
  1383. type: object
  1384. properties: {}
  1385. description: 注销账号 Response
  1386. api.user.v2.UpdateAlarmClockRequest:
  1387. type: object
  1388. properties:
  1389. cid:
  1390. type: string
  1391. description: 小孩ID
  1392. label:
  1393. type: string
  1394. description: 闹钟标签
  1395. repeats:
  1396. type: string
  1397. description: '重复天 eg: 1000000 周一开启 1111100 工作日开启'
  1398. time:
  1399. type: string
  1400. description: 'Time 闹钟时间 格式: HH:mm'
  1401. onceTime:
  1402. type: string
  1403. description: 仅一次时间戳
  1404. id:
  1405. type: string
  1406. description: 闹钟ID
  1407. status:
  1408. type: boolean
  1409. description: 是否开启
  1410. description: 修改闹钟 Request
  1411. api.user.v2.UpdateAlarmClockResponse:
  1412. type: object
  1413. properties: {}
  1414. description: 修改闹钟 Response
  1415. api.user.v2.UpdateChildRequest:
  1416. type: object
  1417. properties:
  1418. name:
  1419. type: string
  1420. description: 小孩姓名
  1421. phoneNumber:
  1422. type: string
  1423. description: 小孩电话
  1424. areaCode:
  1425. type: string
  1426. description: 小孩电话区号
  1427. avatar:
  1428. type: string
  1429. description: 小孩头像
  1430. birthday:
  1431. type: string
  1432. description: 小孩生日
  1433. appellation:
  1434. type: string
  1435. description: 小孩对自己的称谓
  1436. gender:
  1437. type: integer
  1438. description: 小孩性别
  1439. format: enum
  1440. weight:
  1441. type: integer
  1442. description: 小孩体重
  1443. format: int32
  1444. height:
  1445. type: integer
  1446. description: 小孩身高
  1447. format: int32
  1448. cid:
  1449. type: string
  1450. description: 小孩ID
  1451. api.user.v2.UpdateChildResponse:
  1452. type: object
  1453. properties: {}
  1454. api.user.v2.UpdateContactPersonRequest:
  1455. type: object
  1456. properties:
  1457. id:
  1458. type: string
  1459. avatar:
  1460. type: string
  1461. phoneNumber:
  1462. type: string
  1463. areaCode:
  1464. type: string
  1465. appellation:
  1466. type: string
  1467. role:
  1468. type: integer
  1469. format: enum
  1470. uid:
  1471. type: string
  1472. description: 更新联系人 Request
  1473. api.user.v2.UpdateContactPersonResponse:
  1474. type: object
  1475. properties: {}
  1476. description: 更新联系人 Response
  1477. api.user.v2.UpdateSchoolDisableRequest:
  1478. type: object
  1479. properties:
  1480. id:
  1481. type: string
  1482. cid:
  1483. type: string
  1484. repeats:
  1485. type: string
  1486. startTime:
  1487. type: string
  1488. endTime:
  1489. type: string
  1490. status:
  1491. type: boolean
  1492. description: 更新上课禁用 Request
  1493. api.user.v2.UpdateSchoolDisableResponse:
  1494. type: object
  1495. properties: {}
  1496. description: 更新上课禁用 Response
  1497. tags:
  1498. - name: AlarmClock
  1499. - name: Child
  1500. - name: Contacts
  1501. - name: Device
  1502. description: |-
  1503. 设备服务
  1504. - 绑定设备
  1505. - 解绑设备
  1506. - 查询设备绑定状态
  1507. - 设备交换三码
  1508. - name: Message
  1509. - name: PublishRegistration
  1510. - name: SchoolDisable
  1511. - name: User