Skip to content

Commit

Permalink
feat(api): update via SDK Studio
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-bot committed May 28, 2024
1 parent d57c0ae commit 65994d2
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 0 deletions.
5 changes: 5 additions & 0 deletions committestresult.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package openlayer

import (
"context"
"errors"
"fmt"
"net/http"
"net/url"
Expand Down Expand Up @@ -41,6 +42,10 @@ func NewCommitTestResultService(opts ...option.RequestOption) (r *CommitTestResu
// List the test results for a commit (project version).
func (r *CommitTestResultService) List(ctx context.Context, id string, query CommitTestResultListParams, opts ...option.RequestOption) (res *CommitTestResultListResponse, err error) {
opts = append(r.Options[:], opts...)
if id == "" {
err = errors.New("missing required id parameter")
return
}
path := fmt.Sprintf("versions/%s/results", id)
err = requestconfig.ExecuteNewRequest(ctx, http.MethodGet, path, query, &res, opts...)
return
Expand Down
5 changes: 5 additions & 0 deletions inferencepipelinedata.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package openlayer

import (
"context"
"errors"
"fmt"
"net/http"

Expand Down Expand Up @@ -35,6 +36,10 @@ func NewInferencePipelineDataService(opts ...option.RequestOption) (r *Inference
// Stream production data to an inference pipeline in Openlayer.
func (r *InferencePipelineDataService) Stream(ctx context.Context, id string, body InferencePipelineDataStreamParams, opts ...option.RequestOption) (res *InferencePipelineDataStreamResponse, err error) {
opts = append(r.Options[:], opts...)
if id == "" {
err = errors.New("missing required id parameter")
return
}
path := fmt.Sprintf("inference-pipelines/%s/data-stream", id)
err = requestconfig.ExecuteNewRequest(ctx, http.MethodPost, path, body, &res, opts...)
return
Expand Down
5 changes: 5 additions & 0 deletions inferencepipelinetestresult.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package openlayer

import (
"context"
"errors"
"fmt"
"net/http"
"net/url"
Expand Down Expand Up @@ -41,6 +42,10 @@ func NewInferencePipelineTestResultService(opts ...option.RequestOption) (r *Inf
// List the test results under an inference pipeline.
func (r *InferencePipelineTestResultService) List(ctx context.Context, id string, query InferencePipelineTestResultListParams, opts ...option.RequestOption) (res *InferencePipelineTestResultListResponse, err error) {
opts = append(r.Options[:], opts...)
if id == "" {
err = errors.New("missing required id parameter")
return
}
path := fmt.Sprintf("inference-pipelines/%s/results", id)
err = requestconfig.ExecuteNewRequest(ctx, http.MethodGet, path, query, &res, opts...)
return
Expand Down
5 changes: 5 additions & 0 deletions projectcommit.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package openlayer

import (
"context"
"errors"
"fmt"
"net/http"
"net/url"
Expand Down Expand Up @@ -38,6 +39,10 @@ func NewProjectCommitService(opts ...option.RequestOption) (r *ProjectCommitServ
// List the commits (project versions) under a project.
func (r *ProjectCommitService) List(ctx context.Context, id string, query ProjectCommitListParams, opts ...option.RequestOption) (res *ProjectCommitListResponse, err error) {
opts = append(r.Options[:], opts...)
if id == "" {
err = errors.New("missing required id parameter")
return
}
path := fmt.Sprintf("projects/%s/versions", id)
err = requestconfig.ExecuteNewRequest(ctx, http.MethodGet, path, query, &res, opts...)
return
Expand Down
5 changes: 5 additions & 0 deletions projectinferencepipeline.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package openlayer

import (
"context"
"errors"
"fmt"
"net/http"
"net/url"
Expand Down Expand Up @@ -38,6 +39,10 @@ func NewProjectInferencePipelineService(opts ...option.RequestOption) (r *Projec
// List the inference pipelines in a project.
func (r *ProjectInferencePipelineService) List(ctx context.Context, id string, query ProjectInferencePipelineListParams, opts ...option.RequestOption) (res *ProjectInferencePipelineListResponse, err error) {
opts = append(r.Options[:], opts...)
if id == "" {
err = errors.New("missing required id parameter")
return
}
path := fmt.Sprintf("projects/%s/inference-pipelines", id)
err = requestconfig.ExecuteNewRequest(ctx, http.MethodGet, path, query, &res, opts...)
return
Expand Down

0 comments on commit 65994d2

Please sign in to comment.