MCPcopy Index your code
hub / github.com/coder/coder / InsertAIProvider

Method InsertAIProvider

coderd/database/queries.sql.go:603–629  ·  view source on GitHub ↗
(ctx context.Context, arg InsertAIProviderParams)

Source from the content-addressed store, hash-verified

601}
602
603func (q *sqlQuerier) InsertAIProvider(ctx context.Context, arg InsertAIProviderParams) (AIProvider, error) {
604 row := q.db.QueryRowContext(ctx, insertAIProvider,
605 arg.ID,
606 arg.Type,
607 arg.Name,
608 arg.DisplayName,
609 arg.Enabled,
610 arg.BaseUrl,
611 arg.Settings,
612 arg.SettingsKeyID,
613 )
614 var i AIProvider
615 err := row.Scan(
616 &i.ID,
617 &i.Type,
618 &i.Name,
619 &i.DisplayName,
620 &i.Enabled,
621 &i.Deleted,
622 &i.BaseUrl,
623 &i.Settings,
624 &i.SettingsKeyID,
625 &i.CreatedAt,
626 &i.UpdatedAt,
627 )
628 return i, err
629}
630
631const updateAIProvider = `-- name: UpdateAIProvider :one
632UPDATE

Callers

nothing calls this directly

Calls 2

QueryRowContextMethod · 0.80
ScanMethod · 0.45

Tested by

no test coverage detected