Sha256: a2f1eb130df290fb5324fa47ffebd6c714784fffb3f52c64ffeb0d0f04f59f1f
Contents?: true
Size: 458 Bytes
Versions: 16
Compression:
Stored size: 458 Bytes
Contents
module TrackerApi module Endpoints class FileAttachment attr_accessor :client def initialize(client) @client = client end def create(project_id, file_name, content_type) body = {file: Faraday::UploadIO.new(file_name, content_type)} data = client.post("/projects/#{project_id}/uploads", body: body).body Resources::FileAttachment.new({ client: client }.merge(data)) end end end end
Version data entries
16 entries across 16 versions & 1 rubygems