lib/calendly/models/organization.rb in calendly-0.11.1 vs lib/calendly/models/organization.rb in calendly-0.12.0
- old
+ new
@@ -43,12 +43,11 @@
#
# @param [Hash] options the optional request parameters. Optional.
# @option options [Integer] :count Number of rows to return.
# @option options [String] :email Filter by email.
# @option options [String] :page_token Pass this to get the next portion of collection.
- # @option options [String] :sort Order results by the specified field and directin.
- # Accepts comma-separated list of {field}:{direction} values.
+ # @option options [String] :sort Order results by the specified field and directin. Accepts comma-separated list of {field}:{direction} values.
# @option options [String] :status Filter by status.
# @return [Array<Calendly::OrganizationInvitation>]
# @raise [Calendly::Error] if the uuid is empty.
# @raise [Calendly::ApiError] if the api returns error code.
# @since 0.1.0
@@ -83,12 +82,11 @@
#
# @param [Hash] options the optional request parameters. Optional.
# @option options [Boolean] :active Return only active event types if true, only inactive if false, or all event types if this parameter is omitted.
# @option options [Integer] :count Number of rows to return.
# @option options [String] :page_token Pass this to get the next portion of collection.
- # @option options [String] :sort Order results by the specified field and direction.
- # Accepts comma-separated list of {field}:{direction} values.
+ # @option options [String] :sort Order results by the specified field and direction. Accepts comma-separated list of {field}:{direction} values.
# @return [Array<Calendly::EventType>]
# @raise [Calendly::Error] if the uri is empty.
# @raise [Calendly::ApiError] if the api returns error code.
# @since 0.6.0
def event_types(options: nil)
@@ -111,12 +109,11 @@
# @option options [Integer] :count Number of rows to return.
# @option options [String] :invitee_email Return events scheduled with the specified invitee email
# @option options [String] :max_start_timeUpper bound (inclusive) for an event's start time to filter by.
# @option options [String] :min_start_time Lower bound (inclusive) for an event's start time to filter by.
# @option options [String] :page_token Pass this to get the next portion of collection.
- # @option options [String] :sort Order results by the specified field and directin.
- # Accepts comma-separated list of {field}:{direction} values.
+ # @option options [String] :sort Order results by the specified field and directin. Accepts comma-separated list of {field}:{direction} values.
# @option options [String] :status Whether the scheduled event is active or canceled
# @return [Array<Calendly::Event>]
# @raise [Calendly::Error] if the uri is empty.
# @raise [Calendly::ApiError] if the api returns error code.
# @since 0.5.0
@@ -138,11 +135,10 @@
#
# @param [Hash] options the optional request parameters. Optional.
# @option options [Integer] :count Number of rows to return.
# @option options [String] :page_token Pass this to get the next portion of collection.
# @option options [String] :sort Order results by the specified field and directin. Accepts comma-separated list of {field}:{direction} values.
- # Accepts comma-separated list of {field}:{direction} values.
# @return [Array<Calendly::WebhookSubscription>]
# @raise [Calendly::Error] if the uri is empty.
# @raise [Calendly::ApiError] if the api returns error code.
# @since 0.1.3
def webhooks(options: nil)
@@ -170,8 +166,32 @@
# @raise [Calendly::Error] if the uri is empty.
# @raise [Calendly::ApiError] if the api returns error code.
# @since 0.1.3
def create_webhook(url, events, signing_key: nil)
client.create_webhook url, events, uri, signing_key: signing_key
+ end
+
+ #
+ # Returns all Routing Forms associated with self.
+ #
+ # @param [Hash] options the optional request parameters. Optional.
+ # @option options [Integer] :count Number of rows to return.
+ # @option options [String] :page_token Pass this to get the next portion of collection.
+ # @option options [String] :sort Order results by the specified field and directin. Accepts comma-separated list of {field}:{direction} values.
+ # @return [Array<Calendly::RoutingForm>]
+ # @raise [Calendly::Error] if the uri is empty.
+ # @raise [Calendly::ApiError] if the api returns error code.
+ # @since 0.12.0
+ def routing_forms(options: nil)
+ return @cached_routing_forms if defined?(@cached_routing_forms) && @cached_routing_forms
+
+ request_proc = proc { |opts| client.routing_forms uri, options: opts }
+ @cached_routing_forms = auto_pagination request_proc, options
+ end
+
+ # @since 0.12.0
+ def routing_forms!(options: nil)
+ @cached_routing_forms = nil
+ routing_forms options: options
end
end
end