Skip to content

Public Profile

Every user has a public-facing personal page that other authenticated users can view. The public profile shows the user’s display name, major, interests, created events/gigs, follower count, and following count.

GET /api/v1/users/:id returns the public profile of user :id.

FieldVisibility
idPublic
displayNamePublic
majorPublic
gradYearPublic
interestsPublic
followerCountPublic
followingCountPublic
createdEventsPublic (paginated)
isFollowingPublic (whether the authenticated user follows this user)
emailPrivate (only visible to the user themselves via /api/v1/users/me)

Any authenticated user can view any other user’s public profile. The response includes whether the authenticated user currently follows this user (isFollowing boolean).

The public profile includes the user’s created events/gigs (source = USER), paginated. Only OPEN and IN_PROGRESS events are shown (not CANCELLED or COMPLETED).

If the user ID does not exist, the API responds with 404.

GIVEN user B exists with displayName "Brutus", major "CS", interests ["sports"]
AND user B has 10 followers and follows 5 users
WHEN user A sends GET /api/v1/users/B
THEN the response contains displayName "Brutus", major "CS", interests ["sports"], followerCount 10, followingCount 5
AND isFollowing indicates whether user A follows user B

S-PUB-2: Email not visible on public profile

Section titled “S-PUB-2: Email not visible on public profile”
GIVEN user B exists with email "brutus@osu.edu"
WHEN user A sends GET /api/v1/users/B
THEN the response does not contain the email field
GIVEN user B created 3 events (2 OPEN, 1 CANCELLED)
WHEN user A sends GET /api/v1/users/B
THEN the response includes 2 events (the OPEN ones)
AND the CANCELLED event is not included
GIVEN user A follows user B
WHEN user A sends GET /api/v1/users/B
THEN isFollowing is true
GIVEN user A does not follow user B
WHEN user A sends GET /api/v1/users/B
THEN isFollowing is false
GIVEN no user exists with id "nonexistent"
WHEN user A sends GET /api/v1/users/nonexistent
THEN the API responds with 404 Not Found