Sha256: 13020ac30e383ee7e4ce000a0c7d6c013ada4a4239692cd1e51578addd36e508

Contents?: true

Size: 665 Bytes

Versions: 1

Compression:

Stored size: 665 Bytes

Contents

module OEmbed
  class Providers
    # Provider for spotify.com
    # https://developer.spotify.com/documentation/embeds/reference/oembed
    # https://developer.spotify.com/documentation/embeds/tutorials/using-the-oembed-api
    Spotify = OEmbed::Provider.new(
      "https://open.spotify.com/oembed",
      format: :json
    )
    Spotify << "http://open.spotify.com/*"
    Spotify << "https://open.spotify.com/*"
    Spotify << "http://play.spotify.com/*"
    Spotify << "https://play.spotify.com/*"
    # https://developer.spotify.com/documentation/web-api/concepts/spotify-uris-ids
    Spotify << /^spotify\:(.*?)/

    add_official_provider(Spotify)
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
ruby-oembed-0.18.1 lib/oembed/providers/spotify.rb