Sha256: e619bf8ca71574707c623064a4e8a09a183c947bc0434d53e05df9188239c7a5
Contents?: true
Size: 1.19 KB
Versions: 5
Compression:
Stored size: 1.19 KB
Contents
module Mangadex class ChapterReadMarker extend T::Sig sig { params(id: String).returns(T::Api::GenericResponse) } def self.get(id) Mangadex::Internal::Definition.must(id) Mangadex::Internal::Request.get( '/manga/{id}/read' % {id: id} ) end sig { params(id: String, args: T::Api::Arguments).returns(T::Api::GenericResponse) } def self.create(id, **args) Mangadex::Internal::Definition.must(id) Mangadex::Internal::Request.post( '/manga/{id}/read' % {id: id}, payload: Mangadex::Internal::Definition.validate(args, { update_history: { accepts: [true, false] } }) ) end sig { sig(args: T::Api::Arguments).returns(T::Api::GenericResponse) } def self.list(**args) Mangadex::Internal::Request.get( '/manga/list', Mangadex::Internal::Definition.validate(args, { ids: { accepts: [String], converts: :to_a, required: true }, grouped: { accepts: [true, false] }, }) ) end sig { returns(T::Api::GenericResponse) } def self.user_list Mangadex::Internal::Request.get( '/user/history', auth: true, ) end end end
Version data entries
5 entries across 5 versions & 1 rubygems