Skip to content
Snippets Groups Projects

feat: Impl profile endpoint + tests

8 files
+ 559
11
Compare changes
  • Side-by-side
  • Inline
Files
8
+ 167
0
@@ -104,6 +104,26 @@ paths:
500:
description: Error while retrieving data
/profile:
get:
tags:
- Profile
summary: User profile
description: Fetch the profile data for the current user.
security:
- OAuth2: [openvsx_publisher_agreement, openid, profile]
responses:
200:
description: Success
content:
application/json:
schema:
$ref: "#/components/schemas/EfUser"
403:
description: Invalid credentials
500:
description: Error while retrieving data
components:
securitySchemes:
OAuth2:
@@ -177,3 +197,150 @@ components:
- type: string
- type: "null"
description: The URL
EfUser:
type: object
properties:
uid:
type: integer
description: The unique user id.
name:
type: string
description: The user's ef username name.
picture:
type: string
description: URL of the user's picture.
mail:
oneOf:
- type: string
- type: "null"
description: The user's email.
eca:
oneOf:
- $ref: "#/components/schemas/Eca"
- type: "null"
is_committer:
oneOf:
- type: boolean
- type: "null"
description: User's committer status.
friends:
oneOf:
- $ref: "#/components/schemas/Friends"
- type: "null"
first_name:
type: string
description: The user's first name.
last_name:
type: string
description: The user's last name.
publisher_agreements:
type: object
propertyNames:
description: The publisher agreement name.
additionalProperties:
$ref: "#/components/schemas/ProfilePublisherAgreement"
github_handle:
type: string
description: The user's Github handle.
twitter_handle:
type: string
description: The user's Twitter handle.
org:
type: string
description: The user's organization.
org_id:
oneOf:
- type: string
- type: "null"
description: The user's organization id.
job_title:
type: string
description: The user's job title at the organization.
website:
type: string
description: The user's website.
country:
$ref: "#/components/schemas/Country"
bio:
oneOf:
- type: string
- type: "null"
description: The user's account bio
interests:
type: array
items:
type: string
description: A list of the user's interests.
working_groups_interests:
type: array
items:
type: string
description: A list of the user's working group interests.
forums_url:
oneOf:
- type: string
- type: "null"
description: The user's forum URL.
gerrit_url:
oneOf:
- type: string
- type: "null"
description: The user's Gerrit URL.
projects_url:
oneOf:
- type: string
- type: "null"
description: The user's projects URL.
mailinglist_url:
oneOf:
- type: string
- type: "null"
description: The user's mailing list URL.
mpc_favorites_url:
oneOf:
- type: string
- type: "null"
description: The user's Marketplace favorites URL.
Eca:
type: object
properties:
signed:
type: boolean
description: Flag determining whether user has signed ECA.
can_contribute_spec_project:
type: boolean
description: Flag determining whether users can contribute to a spec project.
example:
signed: true
can_contribute_spec_project: true
Friends:
type: object
properties:
friend_id:
type: integer
description: The friend's userid.
example:
friend_id: 6104
Country:
type: object
properties:
code:
type: string
description: The country code.
name:
type: string
description: The country name.
example:
code: CA
name: Canada
ProfilePublisherAgreement:
type: object
properties:
version:
type: string
description: the agreement document version.
Loading