LogoLogo
  • 🕴️ QUICK START GUIDE
  • DASHBOARD
    • Management
      • Add a new Game
        • Create a Game
        • Set-Up
        • Review Guidelines
      • Version control
        • Add a Build
        • Handle branches
        • Upgrade Versions
      • API Keys
    • NFT Collections
      • Add a Collection
      • Staking Support
    • Beta Codes
      • Create a Beta Code
    • Tournaments
      • Set Up
      • Create Tournament
    • In-App Purchases
      • Developer
        • Set up your Store
        • Submit Product
        • Client Integration
        • Handle Post-Payments
      • Payment Gateways
      • Review Guidelines
    • Elixir Invisible Wallet
      • Gas Manager
        • Create Gas Manager
        • Handle Balances
    • Reward Center
      • Game Quests
        • Add a Stat
        • Create a Quest
        • Test Your Quest
        • Submit your Quest
        • Update Progress
        • Review Guidelines
  • Elixir Gamer Services
    • 🏁Kick-off
    • Unity
      • Getting Started
        • Overview
        • Updates
          • GitHub
          • Unity Asset Store (Coming Soon)
      • Overlay
        • Overlay Actions
        • Event Simulator
          • SDK Events
      • Authentication
        • Desktop
        • Mobile
      • Reference
    • Unreal Engine
      • Getting Started
        • C++ Project
        • Blueprints Project
  • API
    • Elixir REST API
      • 🖥️Desktop Auth
      • 📱Mobile Auth
      • 🔐RSA Signature
        • 🔢C# Example
        • 🔢Node.js Example
      • 🧔User
      • 👾NFTs
      • 🏆Tournaments API
      • ❓Game Quests
    • How To
      • Link Elixir account to a game API account
Powered by GitBook
On this page
  • Overview
  • Userinfo/Open ID
  • User Friend List

Was this helpful?

Export as PDF
  1. API
  2. Elixir REST API

User

Obtaining Elixir User information

Overview

The user info provides information about the user's public profile in Elixir. This endpoint can validate the Elixir JWT as an OpenID system. Besides, the game can get the wallets of the user in case they are needed.

Userinfo/Open ID

GET https://kend.elixir.app/sdk/v2/userinfo

Method to provide all Elixir User-related info. Works as an OpenId to validate the user JWT.

Headers

Name
Type
Description

x-api-key*

String

Public Key available on the Developer Dashboard

authorization*

String

A string containing the JWT as follows: "Bearer <jwt>"

{
    "code": 1,
    "success": true,
    "data": {
        "sub": "aea...36",
        "wallets": [
            "BINANCE:0xB...8",
            "SOLANA:Eb...1w"
        ],
        "nickname": "rega",
        "picture": "https://...",
        "status": "ACTIVE",
        "email": "user@email.com",
        "email_verified": true,
        "aud": "game:production",
        "iss": "gameId",
        "iat": 1675127300,
        "exp": 1675386500
    }
}
{
    "code": -1,
    "success": false,
    "error": {
        "status": 400,
        "code": 1001,
        "message": "The argument 'encoding' is invalid for data of length 1151. Received 'hex'"
    }
}

User Friend List

GET https://kend.elixir.app/sdk/v2/friends/

Get the Friend List for a given user. Friend information is provided so it can be displayed with avatars. Each friend ElixirId is available on the friendId field

Headers

Name
Type
Description

x-api-key*

String

Public Key available on the Developer Dashboard

authorization*

String

A string containing the JWT as follows: "Bearer <jwt>"

{
    "code": 1,
    "success": true,
    "data": [
        {
            "friendId": "9ce7916c-de8e-44c8-b4aa-455385c601a6",
            "username": "sniper-4015",
            "name": "Sniper",
            "avatar": "https://d1udajbuf50cfc.cloudfront.net/avatar/9ce7916c-de8e-44c8-b4aa-455385c601a6/1675145810918_screenshot_2023_01_18_at_14_52_08_png",
            "isVerifiedNFTAvatar": false,
            "friendStatus": "ACCEPTED",
            "status": "OFFLINE",
            "playStatus": {
                "playing": false
            }
        },
        {
            "friendId": "a2a1f018-c836-4041-bd2d-95a7c4734d36",
            "username": "gunner-8634",
            "name": "Gunner",
            "avatar": "https://d1udajbuf50cfc.cloudfront.net/avatar/aea1f008-c8a6-4041-bd2d-95a7c4735d36/greenie.gif",
            "isVerifiedNFTAvatar": true,
            "friendStatus": "ACCEPTED",
            "status": "OFFLINE",
            "playStatus": {
                "playing": false
            }
        }
    ]
}
PreviousNode.js ExampleNextNFTs

Last updated 2 years ago

Was this helpful?

🧔