Skip to content

speakeasy-api/speakeasy-client-sdk-ruby

Repository files navigation

speakeasy_client_sdk_ruby

Developer-friendly & type-safe Ruby SDK specifically catered to leverage speakeasy_client_sdk_ruby API.



Important

This SDK is not yet ready for production use. To complete setup please follow the steps outlined in your workspace. Delete this section before > publishing to a package manager.

Summary

Speakeasy API: The Speakeasy API allows teams to manage common operations with their APIs

For more information about the API: The Speakeasy Platform Documentation

Table of Contents

SDK Installation

The SDK can be installed using RubyGems:

gem install speakeasy_client_sdk_ruby

SDK Example Usage

Example

require 'speakeasy_client_sdk_ruby'


s = ::OpenApiSDK::SpeakeasyClientSDK.new
s.config_security(
  ::OpenApiSDK::Shared::Security.new(
    api_key: "<YOUR_API_KEY_HERE>",
  )
)

    
res = s.apis.get_all(op=::OpenApiSDK::Operations::Op.new(
  and_: false,
), metadata={
  "key": [
    "<value>",
  ],
})

if ! res.apis.nil?
  # handle response
end

Available Resources and Operations

Available methods
  • list - Get all Api endpoints for a particular apiID.
  • get_access_token - Get an embed access token for the current workspace.
  • get_valid - Get all valid embed access tokens for the current workspace.
  • delete - Revoke an embed access EmbedToken.
  • search - Search events for a particular workspace by any field
  • post - Post events for a specific workspace
  • get_by_target - Load recent events for a particular workspace
  • get_targets - Load targets for a particular workspace
  • get_targets_deprecated - Load targets for a particular workspace
  • get - Get all metadata for a particular apiID and versionID.
  • insert_version - Insert metadata for a particular apiID and versionID.
  • delete_version - Delete metadata for a particular apiID and versionID.
  • get_all - Get organizations for a user
  • create - Create an organization
  • get - Get organization
  • create_free_trial - Create a free trial for an organization
  • get_usage - Get billing usage summary for a particular organization
  • upload - Upload a report.
  • get_signed_url - Get the signed access url for the linting reports for a particular document.
  • get_changes_signed_url - Get the signed access url for the change reports for a particular document.
  • query - Query the event log to retrieve a list of requests.
  • get - Get information about a particular request.
  • generate_postman_collection - Generate a Postman collection for a particular request.
  • get_latest - Get information about the latest schema.
  • post - Register a schema.
  • download - Download the latest schema for a particular apiID.
  • get_diff - Get a diff of two schema revisions for an Api.
  • delete - Delete a particular schema revision for an Api.
  • get_revision - Get information about a particular schema revision for an Api.
  • download_revision - Download a particular schema revision for an Api.
  • get - Get information about all schemas associated with a particular apiID.
  • get_all - Get all ApiEndpoints for a particular apiID and versionID.
  • find - Find an ApiEndpoint via its displayName.
  • delete - Delete an ApiEndpoint.
  • get - Get an ApiEndpoint.
  • upsert - Upsert an ApiEndpoint.
  • generate_open_api_spec - Generate an OpenAPI specification for a particular ApiEndpoint.
  • generate_postman_collection - Generate a Postman collection for a particular ApiEndpoint.
  • openapi - (DEPRECATED) Generate suggestions for improving an OpenAPI document.
  • generate - Generate suggestions for improving an OpenAPI document.
  • openapi_registry - Generate suggestions for improving an OpenAPI document stored in the registry.

Server Selection

Server Selection

Select Server by Name

You can override the default server globally by passing a server name to the server: str optional parameter when initializing the SDK client instance. The selected server will then be used as the default on the operations that use it. This table lists the names associated with the available servers:

Name Server Variables
prod https://api.prod.speakeasyapi.dev None

Override Server URL Per-Client

The default server can also be overridden globally by passing a URL to the server_url: str optional parameter when initializing the SDK client instance. For example:

Development

Maturity

This SDK is in beta, and there may be breaking changes between versions without a major version update. Therefore, we recommend pinning usage to a specific package version. This way, you can install the same version each time without breaking changes unless you are intentionally looking for the latest version.

Contributions

While we value open-source contributions to this SDK, this library is generated programmatically. Any manual changes added to internal files will be overwritten on the next generation. We look forward to hearing your feedback. Feel free to open a PR or an issue with a proof of concept and we'll do our best to include it in a future release.

SDK Created by Speakeasy