{"servers":[{"url":"https://auth.campusone.com.ng/api/apps"}],"info":{"title":"Campus One — Connected App API","version":"1.0.0","description":"Endpoints connected apps call with their OAuth Bearer access token to push notifications and calendar events to the authorizing user."},"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"OAuth 2.0 access token issued to the connected app via the OIDC flow."}}},"openapi":"3.1.1","paths":{"/notifications":{"post":{"operationId":"send","summary":"Send a notification to the authenticated user","description":"Delivers an in-app notification to the user who authorized this app. Requires the `notifications` OAuth scope and the app's notifications permission. Pass an `Idempotency-Key` header to make retries safe — a repeated key returns the original notification instead of creating a new one.","tags":["Notifications"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":128},"body":{"type":"string","minLength":1,"maxLength":512},"type":{"enum":["info","success","warning","action_required"],"type":"string","default":"info"},"targetUrl":{"anyOf":[{"type":"string","format":"uri"},{"type":"null"}]}},"required":["title","body"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"userId":{"type":"string"},"appId":{"anyOf":[{"type":"string"},{"type":"null"}]},"title":{"type":"string"},"body":{"type":"string"},"type":{"type":"string"},"unread":{"type":"boolean"},"targetUrl":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","x-native-type":"date"},"updatedAt":{"type":"string","format":"date-time","x-native-type":"date"}},"required":["id","userId","appId","title","body","type","unread","targetUrl","createdAt","updatedAt"]}}}}}}},"/events":{"post":{"operationId":"create","summary":"Create a calendar event for the authenticated user","description":"Creates a calendar event for the user who authorized this app. Requires the `events` OAuth scope and the app's events permission. Pass an `Idempotency-Key` header to make retries safe — a repeated key returns the original event instead of creating a duplicate.","tags":["Events"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"startsAt":{"type":"string","format":"date-time"},"endsAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"location":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"url":{"anyOf":[{"type":"string","format":"uri"},{"type":"null"}]}},"required":["title","startsAt"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"userId":{"type":"string"},"appId":{"anyOf":[{"type":"string"},{"type":"null"}]},"title":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"startsAt":{"type":"string","format":"date-time","x-native-type":"date"},"endsAt":{"anyOf":[{"type":"string","format":"date-time","x-native-type":"date"},{"type":"null"}]},"location":{"anyOf":[{"type":"string"},{"type":"null"}]},"url":{"anyOf":[{"type":"string"},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","x-native-type":"date"},"updatedAt":{"type":"string","format":"date-time","x-native-type":"date"}},"required":["id","userId","appId","title","description","startsAt","endsAt","location","url","createdAt","updatedAt"]}}}}}}}}}