Documentation
¶
Index ¶
- type Client
- func (c *Client) GetSubmissionLogs(ctx context.Context, id string) (io.ReadCloser, error)
- func (c *Client) GetSubmissionStatus(ctx context.Context, id string) (*SubmissionStatus, error)
- func (c *Client) NewSubmission(ctx context.Context, name, sha256sum string) (*NewSubmissionResponse, error)
- func (c *Client) SubmitFile(ctx context.Context, name string, f io.ReadSeeker) (string, error)
- func (c *Client) Upload(ctx context.Context, attr *UploadAttributes, f io.ReadSeeker) error
- type NewSubmissionResponse
- type StatusCode
- type SubmissionStatus
- type UploadAttributes
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
func (*Client) GetSubmissionLogs ¶
func (*Client) GetSubmissionStatus ¶
func (*Client) NewSubmission ¶
func (c *Client) NewSubmission(ctx context.Context, name, sha256sum string) (*NewSubmissionResponse, error)
NewSubmission initiates a submission for the given file and returns attributes used to upload it for evaluation.
func (*Client) SubmitFile ¶
SubmitFile initiates a submission and uploads its contents without waiting for it to finish. Returns the ID of the submission.
func (*Client) Upload ¶
func (c *Client) Upload(ctx context.Context, attr *UploadAttributes, f io.ReadSeeker) error
type NewSubmissionResponse ¶
type NewSubmissionResponse struct { Attributes UploadAttributes `json:"attributes"` ID string `json:"id"` Type string `json:"type"` }
type StatusCode ¶
type StatusCode string
const ( StatusInProgress StatusCode = "In Progress" StatusAccepted StatusCode = "Accepted" StatusRejected StatusCode = "Rejected" )
type SubmissionStatus ¶
type UploadAttributes ¶
type UploadAttributes struct { AWSAccessKeyID string `json:"awsAccessKeyId"` AWSSecretAccessKey string `json:"awsSecretAccessKey"` AWSSessionToken string `json:"awsSessionToken"` Bucket string `json:"bucket"` Object string `json:"object"` }
func (*UploadAttributes) Validate ¶
func (a *UploadAttributes) Validate() error
Click to show internal directories.
Click to hide internal directories.