Module: Bitly::API::BSD

Defined in:
lib/bitly/api/bsd.rb

Defined Under Namespace

Classes: List

Class Method Summary collapse

Class Method Details

.list(client:) ⇒ Array<String>

Fetch Branded Short Domains (BSDs). [‘GET /v4/bsds`](dev.bitly.com/api-reference/#getBSDs)

Examples:

bsds = Bitly::API::BSD.list(client: client)

Returns:

  • (Array<String>)


17
18
19
20
21
# File 'lib/bitly/api/bsd.rb', line 17

def self.list(client:)
  response = client.request(path: "/bsds")
  bsds = response.body["bsds"]
  List.new(items: bsds, response: response)
end