From 555f025d1011ff657277b91bfd177bd4f7e1a9b0 Mon Sep 17 00:00:00 2001 From: Josiah Glosson Date: Sat, 28 Mar 2026 07:43:24 -0500 Subject: [PATCH] Add `inGameName` to `/api/user/{userId|discordId}` route (#2918) --- app/features/api-public/routes/user.$identifier.ts | 2 ++ app/features/api-public/schema.ts | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/app/features/api-public/routes/user.$identifier.ts b/app/features/api-public/routes/user.$identifier.ts index 1f7877d4a..580ea5dfc 100644 --- a/app/features/api-public/routes/user.$identifier.ts +++ b/app/features/api-public/routes/user.$identifier.ts @@ -32,6 +32,7 @@ export const loader = async ({ params }: LoaderFunctionArgs) => { "User.customUrl", "User.discordId", "User.discordAvatar", + "User.inGameName", "User.pronouns", "PlusTier.tier", jsonArrayFrom( @@ -91,6 +92,7 @@ export const loader = async ({ params }: LoaderFunctionArgs) => { : null, url: `https://sendou.ink/u/${user.customUrl ?? user.discordId}`, country: user.country, + inGameName: user.inGameName, pronouns: user.pronouns, plusServerTier: user.tier as GetUserResponse["plusServerTier"], socials: { diff --git a/app/features/api-public/schema.ts b/app/features/api-public/schema.ts index ea704d04f..6fccd2a02 100644 --- a/app/features/api-public/schema.ts +++ b/app/features/api-public/schema.ts @@ -38,6 +38,12 @@ export interface GetUserResponse { badges: Array; /** Teams user is member of. The main team is always first in the array. */ teams: Array; + /** + * Splatoon 3 splashtag name & ID, if one is set. + * + * @example "Sendou#2955" + */ + inGameName: string | null; /** * User's pronouns. *