Sha256: 8d1c04ccb09c7edea40e3242a221b95ad78edb0a606aff3143a11162e28fdb18

Contents?: true

Size: 399 Bytes

Versions: 8

Compression:

Stored size: 399 Bytes

Contents

module PostmanMta
  class Label < ApplicationModel
    attr_reader :conversation_id

    def initialize(conversation_id)
      @conversation_id = conversation_id
    end

    def create(params)
      post("/api/v1/conversations/#{conversation_id}/labels", body: params)
    end

    def destroy(label_id)
      delete("/api/v1/conversations/#{conversation_id}/labels/#{label_id}")
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
postman_mta-0.1.7 app/models/postman_mta/label.rb
postman_mta-0.1.6 app/models/postman_mta/label.rb
postman_mta-0.1.5 app/models/postman_mta/label.rb
postman_mta-0.1.4 app/models/postman_mta/label.rb
postman_mta-0.1.3 app/models/postman_mta/label.rb
postman_mta-0.1.2 app/models/postman_mta/label.rb
postman_mta-0.1.1 app/models/postman_mta/label.rb
postman_mta-0.1.0 app/models/postman_mta/label.rb