Class: Onlyfans::Resources::ReleaseForms

Inherits:
Object
  • Object
show all
Defined in:
lib/onlyfans/resources/release_forms.rb

Overview

APIs for managing OnlyFans release forms

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ ReleaseForms

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of ReleaseForms.

Parameters:



98
99
100
# File 'lib/onlyfans/resources/release_forms.rb', line 98

def initialize(client:)
  @client = client
end

Instance Method Details

Create a new invitation link for release forms.

Parameters:

  • account (String)

    The Account ID

  • name (String)

    The name of the invitation link.

  • request_options (Onlyfans::RequestOptions, Hash{Symbol=>Object}, nil)

Returns:

See Also:



20
21
22
23
24
25
26
27
28
29
# File 'lib/onlyfans/resources/release_forms.rb', line 20

def create_invitation_link(, params)
  parsed, options = Onlyfans::ReleaseFormCreateInvitationLinkParams.dump_request(params)
  @client.request(
    method: :post,
    path: ["api/%1$s/release-forms/create-invitation-link", ],
    body: parsed,
    model: Onlyfans::Models::ReleaseFormCreateInvitationLinkResponse,
    options: options
  )
end

#create_release_form(account, name:, request_options: {}) ⇒ Onlyfans::Models::ReleaseFormCreateReleaseFormResponse

Create a new release form link.

Parameters:

  • account (String)

    The Account ID

  • name (String)

    The name of the release form.

  • request_options (Onlyfans::RequestOptions, Hash{Symbol=>Object}, nil)

Returns:

See Also:



44
45
46
47
48
49
50
51
52
53
# File 'lib/onlyfans/resources/release_forms.rb', line 44

def create_release_form(, params)
  parsed, options = Onlyfans::ReleaseFormCreateReleaseFormParams.dump_request(params)
  @client.request(
    method: :post,
    path: ["api/%1$s/release-forms/create-release-form", ],
    body: parsed,
    model: Onlyfans::Models::ReleaseFormCreateReleaseFormResponse,
    options: options
  )
end

#list_taggable_users(account, filter: nil, limit: nil, name: nil, offset: nil, sort: nil, sort_direction: nil, request_options: {}) ⇒ Onlyfans::Models::ReleaseFormListTaggableUsersResponse

Some parameter documentations has been truncated, see Models::ReleaseFormListTaggableUsersParams for more details.

Get a paginated list of users that can be tagged in release forms. These are verified creators who have signed release forms to appear in your content. Use ‘offset` and `limit` for pagination.

Parameters:

Returns:

See Also:



83
84
85
86
87
88
89
90
91
92
93
# File 'lib/onlyfans/resources/release_forms.rb', line 83

def list_taggable_users(, params = {})
  parsed, options = Onlyfans::ReleaseFormListTaggableUsersParams.dump_request(params)
  query = Onlyfans::Internal::Util.encode_query_params(parsed)
  @client.request(
    method: :get,
    path: ["api/%1$s/release-forms/taggable-users", ],
    query: query.transform_keys(sort_direction: "sortDirection"),
    model: Onlyfans::Models::ReleaseFormListTaggableUsersResponse,
    options: options
  )
end