* move request_builder into internal pkg (#304) * add some test for internal.RequestBuilder * add a test for openai.GetEngine
This commit is contained in:
committed by
GitHub
parent
62eb4beed2
commit
61ba5f3369
@@ -63,7 +63,7 @@ type ModerationResponse struct {
|
||||
// Moderations — perform a moderation api call over a string.
|
||||
// Input can be an array or slice but a string will reduce the complexity.
|
||||
func (c *Client) Moderations(ctx context.Context, request ModerationRequest) (response ModerationResponse, err error) {
|
||||
req, err := c.requestBuilder.build(ctx, http.MethodPost, c.fullURL("/moderations", request.Model), request)
|
||||
req, err := c.requestBuilder.Build(ctx, http.MethodPost, c.fullURL("/moderations", request.Model), request)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user