Skip to content
DocumentationAPI Reference

Get Current User's Profile

client.Me.Get(ctx) (*MeGetResponse, error)
GET/me

Get detailed profile information about the current user (including the current user's username).

ReturnsExpand Collapse
type MeGetResponse struct{…}
ID stringoptional

The Spotify user ID for the user.

Country stringoptional

The country of the user, as set in the user's account profile. An ISO 3166-1 alpha-2 country code. This field is only available when the current user has granted access to the user-read-private scope.

DisplayName stringoptional

The name displayed on the user's profile. null if not available.

Email stringoptional

The user's email address, as entered by the user when creating their account. Important! This email address is unverified; there is no proof that it actually belongs to the user. This field is only available when the current user has granted access to the user-read-email scope.

ExplicitContent MeGetResponseExplicitContentoptional

The user's explicit content settings. This field is only available when the current user has granted access to the user-read-private scope.

FilterEnabled booloptional

When true, indicates that explicit content should not be played.

FilterLocked booloptional

When true, indicates that the explicit content setting is locked and can't be changed by the user.

Published booloptional

The playlist's public/private status (if it should be added to the user's profile or not): true the playlist will be public, false the playlist will be private, null the playlist status is not relevant. For more about public/private status, see Working with Playlists

ExternalURLs ExternalURLObjectoptional

Known external URLs for this user.

Published booloptional

The playlist's public/private status (if it should be added to the user's profile or not): true the playlist will be public, false the playlist will be private, null the playlist status is not relevant. For more about public/private status, see Working with Playlists

Spotify stringoptional

The Spotify URL for the object.

Followers FollowersObjectoptional

Information about the followers of the user.

Href stringoptional

This will always be set to null, as the Web API does not support it at the moment.

Published booloptional

The playlist's public/private status (if it should be added to the user's profile or not): true the playlist will be public, false the playlist will be private, null the playlist status is not relevant. For more about public/private status, see Working with Playlists

Total int64optional

The total number of followers.

Href stringoptional

A link to the Web API endpoint for this user.

Images []ImageObjectoptional

The user's profile image.

Height int64

The image height in pixels.

URL string

The source URL of the image.

Width int64

The image width in pixels.

Published booloptional

The playlist's public/private status (if it should be added to the user's profile or not): true the playlist will be public, false the playlist will be private, null the playlist status is not relevant. For more about public/private status, see Working with Playlists

Product stringoptional

The user's Spotify subscription level: "premium", "free", etc. (The subscription level "open" can be considered the same as "free".) This field is only available when the current user has granted access to the user-read-private scope.

Published booloptional

The playlist's public/private status (if it should be added to the user's profile or not): true the playlist will be public, false the playlist will be private, null the playlist status is not relevant. For more about public/private status, see Working with Playlists

Type stringoptional

The object type: "user"

Uri stringoptional

The Spotify URI for the user.

Get Current User's Profile

package main

import (
  "context"
  "fmt"

  "github.com/cjavdev/spotted-go"
  "github.com/cjavdev/spotted-go/option"
)

func main() {
  client := spotted.NewClient(
    option.WithAccessToken("My Access Token"),
  )
  me, err := client.Me.Get(context.TODO())
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", me.ID)
}
{
  "id": "id",
  "country": "country",
  "display_name": "display_name",
  "email": "email",
  "explicit_content": {
    "filter_enabled": true,
    "filter_locked": true,
    "published": true
  },
  "external_urls": {
    "published": true,
    "spotify": "spotify"
  },
  "followers": {
    "href": "href",
    "published": true,
    "total": 0
  },
  "href": "href",
  "images": [
    {
      "height": 300,
      "url": "https://i.scdn.co/image/ab67616d00001e02ff9ca10b55ce82ae553c8228\n",
      "width": 300,
      "published": true
    }
  ],
  "product": "product",
  "published": true,
  "type": "type",
  "uri": "uri"
}
Returns Examples
{
  "id": "id",
  "country": "country",
  "display_name": "display_name",
  "email": "email",
  "explicit_content": {
    "filter_enabled": true,
    "filter_locked": true,
    "published": true
  },
  "external_urls": {
    "published": true,
    "spotify": "spotify"
  },
  "followers": {
    "href": "href",
    "published": true,
    "total": 0
  },
  "href": "href",
  "images": [
    {
      "height": 300,
      "url": "https://i.scdn.co/image/ab67616d00001e02ff9ca10b55ce82ae553c8228\n",
      "width": 300,
      "published": true
    }
  ],
  "product": "product",
  "published": true,
  "type": "type",
  "uri": "uri"
}