Skip to content

Erlang OpenAI client auto-generated by OpenAPI-generator

Notifications You must be signed in to change notification settings

dweinstein/openai-erlang-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenAPI client server library for Erlang

Overview

An Erlang client stub generated by OpenAPI Generator given the OpenAPI spec.

Example

1> ApiKey = <<"sk-...">>,
   Host = <<"https://api.openai.com">>,
   HackneyOpts = [{recv_timeout, 30_000}],
   Opts = #{cfg => #{ api_key_prefix => #{ <<"Authorization">> => <<"Bearer">> }, auth => #{ api_key => ApiKey }, host => Host }, hackney_opts => HackneyOpts }),
   openai_open_ai_api:list_models(#{}, Opts).
...
{ok,#{data =>
          [#{created => 1649358449,id => <<"babbage">>,
             object => <<"model">>,owned_by => <<"openai">>,
             parent => null,
             permission =>
                 [#{allow_create_engine => false,allow_fine_tuning => false,
                    allow_logprobs => true,allow_sampling => true,
                    allow_search_indices => false,allow_view => true,
                    created => 1669085501,group => null,
                    id => <<"modelperm-49FUp5v084tBB49tC4z8LPH5">>,
                    is_blocking => false,object => <<"model_permission">>,
                    organization => <<"*">>}],
...

About

Erlang OpenAI client auto-generated by OpenAPI-generator

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages