Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
ef6afa3
wip: create initial routes and queries
ben-fornefeld Mar 16, 2026
4f68d3e
add: resolve team by slug
ben-fornefeld Mar 17, 2026
1477651
revert: outcommented sql migration check in dashboard api
ben-fornefeld Mar 17, 2026
dbb1a2b
chore: auto-commit generated changes
github-actions[bot] Mar 18, 2026
5d8762c
fix: update description for team identity resolution endpoint to clar…
ben-fornefeld Mar 18, 2026
fa21911
Merge remote-tracking branch 'origin/main' into feature/dashboard-sup…
ben-fornefeld Mar 18, 2026
50bcc30
feat: profile picture crud
ben-fornefeld Mar 18, 2026
2de94ee
Merge branch 'feature/dashboard-supabase-admin-migration' of https://…
ben-fornefeld Mar 18, 2026
6fe7b05
chore: auto-commit generated changes
github-actions[bot] Mar 18, 2026
0748d52
chore: move sql and migration files from this branch into separate da…
ben-fornefeld Mar 19, 2026
8b06ebe
Merge branch 'feature/dashboard-supabase-admin-migration' of https://…
ben-fornefeld Mar 19, 2026
df433af
refactor: update database access method in teams_list handler and reg…
ben-fornefeld Mar 19, 2026
49b4887
chore: auto-commit generated changes
github-actions[bot] Mar 19, 2026
340a8d6
refactor: rename GetDefaultTemplateAliases method and remove unused S…
ben-fornefeld Mar 19, 2026
e5fee49
Merge branch 'feature/dashboard-supabase-admin-migration' of https://…
ben-fornefeld Mar 19, 2026
3241207
chore: address comments
ben-fornefeld Mar 19, 2026
9f4abec
improve: team member update error handling + update team profile pict…
ben-fornefeld Mar 19, 2026
265c860
chore: auto-commit generated changes
github-actions[bot] Mar 19, 2026
c9ee454
refactor: standardize team ID naming across API and handlers
ben-fornefeld Mar 19, 2026
4b6c67f
fix: lint
ben-fornefeld Mar 19, 2026
c3715c3
Merge branch 'feature/dashboard-supabase-admin-migration' of https://…
ben-fornefeld Mar 19, 2026
c65a085
chore: share gin body parser utils
ben-fornefeld Mar 20, 2026
63ab90e
refactor: update team member handling and improve error management in…
ben-fornefeld Mar 20, 2026
b2e88ad
test: add unit test for handling deletion of default team members and…
ben-fornefeld Mar 20, 2026
700f36e
chore: auto-commit generated changes
github-actions[bot] Mar 20, 2026
d12ee3b
refactor: team member add/delete handling
ben-fornefeld Mar 20, 2026
91dbdf5
Merge branch 'feature/dashboard-supabase-admin-migration' of https://…
ben-fornefeld Mar 20, 2026
7656ac9
add: team blockage information in teams list
ben-fornefeld Mar 20, 2026
3bd7da4
Merge remote-tracking branch 'origin/main' into feature/dashboard-sup…
ben-fornefeld Mar 20, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/api/internal/handlers/accesstoken.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ import (
"github.com/google/uuid"

"github.com/e2b-dev/infra/packages/api/internal/api"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
authqueries "github.com/e2b-dev/infra/packages/db/pkg/auth/queries"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/keys"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
)
Expand All @@ -22,7 +22,7 @@ func (a *APIStore) PostAccessTokens(c *gin.Context) {

userID := auth.MustGetUserID(c)

body, err := utils.ParseBody[api.NewAccessToken](ctx, c)
body, err := ginutils.ParseBody[api.NewAccessToken](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
4 changes: 2 additions & 2 deletions packages/api/internal/handlers/admin.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import (

"github.com/e2b-dev/infra/packages/api/internal/api"
"github.com/e2b-dev/infra/packages/api/internal/orchestrator"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/shared/pkg/clusters"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
)

Expand Down Expand Up @@ -48,7 +48,7 @@ func (a *APIStore) GetNodesNodeID(c *gin.Context, nodeID api.NodeID, params api.
func (a *APIStore) PostNodesNodeID(c *gin.Context, nodeId api.NodeID) {
ctx := c.Request.Context()

body, err := utils.ParseBody[api.PostNodesNodeIDJSONRequestBody](ctx, c)
body, err := ginutils.ParseBody[api.PostNodesNodeIDJSONRequestBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
6 changes: 3 additions & 3 deletions packages/api/internal/handlers/apikey.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,17 @@ import (

"github.com/e2b-dev/infra/packages/api/internal/api"
"github.com/e2b-dev/infra/packages/api/internal/team"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
"github.com/e2b-dev/infra/packages/db/pkg/auth/queries"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/logger"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
)

func (a *APIStore) PatchApiKeysApiKeyID(c *gin.Context, apiKeyID string) {
ctx := c.Request.Context()

body, err := utils.ParseBody[api.UpdateTeamAPIKey](ctx, c)
body, err := ginutils.ParseBody[api.UpdateTeamAPIKey](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down Expand Up @@ -145,7 +145,7 @@ func (a *APIStore) PostApiKeys(c *gin.Context) {
userID := auth.MustGetUserID(c)
teamID := auth.MustGetTeamInfo(c).Team.ID

body, err := utils.ParseBody[api.NewTeamAPIKey](ctx, c)
body, err := ginutils.ParseBody[api.NewTeamAPIKey](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ import (

"github.com/e2b-dev/infra/packages/api/internal/api"
"github.com/e2b-dev/infra/packages/api/internal/template"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
"github.com/e2b-dev/infra/packages/auth/pkg/types"
"github.com/e2b-dev/infra/packages/db/pkg/dberrors"
"github.com/e2b-dev/infra/packages/shared/pkg/clusters"
"github.com/e2b-dev/infra/packages/shared/pkg/featureflags"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/id"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
"github.com/e2b-dev/infra/packages/shared/pkg/templates"
Expand All @@ -28,7 +28,7 @@ func (a *APIStore) PostTemplates(c *gin.Context) {

userID := auth.MustGetUserID(c)

body, err := utils.ParseBody[api.TemplateBuildRequest](ctx, c)
body, err := ginutils.ParseBody[api.TemplateBuildRequest](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Invalid request body: %s", err))
telemetry.ReportCriticalError(ctx, "invalid request body", err)
Expand Down Expand Up @@ -80,7 +80,7 @@ func (a *APIStore) PostTemplatesTemplateID(c *gin.Context, rawTemplateID api.Tem

userID := auth.MustGetUserID(c)

body, err := utils.ParseBody[api.TemplateBuildRequest](ctx, c)
body, err := ginutils.ParseBody[api.TemplateBuildRequest](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Invalid request body: %s", err))
telemetry.ReportCriticalError(ctx, "invalid request body", err)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@ import (
"github.com/gin-gonic/gin"

"github.com/e2b-dev/infra/packages/api/internal/api"
apiutils "github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
)

// PostV2Templates triggers a new template build
func (a *APIStore) PostV2Templates(c *gin.Context) {
ctx := c.Request.Context()

body, err := apiutils.ParseBody[api.TemplateBuildRequestV2](ctx, c)
body, err := ginutils.ParseBody[api.TemplateBuildRequestV2](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Invalid request body: %s", err))
telemetry.ReportCriticalError(ctx, "invalid request body", err)
Expand Down
3 changes: 2 additions & 1 deletion packages/api/internal/handlers/sandbox_connect.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import (
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
"github.com/e2b-dev/infra/packages/db/pkg/types"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/logger"
sbxlogger "github.com/e2b-dev/infra/packages/shared/pkg/logger/sandbox"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
Expand All @@ -33,7 +34,7 @@ func (a *APIStore) PostSandboxesSandboxIDConnect(c *gin.Context, sandboxID api.S

telemetry.ReportEvent(ctx, "Parsed body")

body, err := utils.ParseBody[api.PostSandboxesSandboxIDConnectJSONRequestBody](ctx, c)
body, err := ginutils.ParseBody[api.PostSandboxesSandboxIDConnectJSONRequestBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
4 changes: 2 additions & 2 deletions packages/api/internal/handlers/sandbox_create.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ import (
templatecache "github.com/e2b-dev/infra/packages/api/internal/cache/templates"
"github.com/e2b-dev/infra/packages/api/internal/middleware/otel/metrics"
"github.com/e2b-dev/infra/packages/api/internal/sandbox"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
sqlcdb "github.com/e2b-dev/infra/packages/db/client"
"github.com/e2b-dev/infra/packages/db/pkg/types"
"github.com/e2b-dev/infra/packages/db/queries"
"github.com/e2b-dev/infra/packages/shared/pkg/clusters"
"github.com/e2b-dev/infra/packages/shared/pkg/featureflags"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/grpc/orchestrator"
"github.com/e2b-dev/infra/packages/shared/pkg/id"
sbxlogger "github.com/e2b-dev/infra/packages/shared/pkg/logger/sandbox"
Expand Down Expand Up @@ -58,7 +58,7 @@ func (a *APIStore) PostSandboxes(c *gin.Context) {
traceID := span.SpanContext().TraceID().String()
c.Set("traceID", traceID)

body, err := utils.ParseBody[api.PostSandboxesJSONRequestBody](ctx, c)
body, err := ginutils.ParseBody[api.PostSandboxesJSONRequestBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
3 changes: 2 additions & 1 deletion packages/api/internal/handlers/sandbox_network_update.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"github.com/e2b-dev/infra/packages/api/internal/api"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
)

Expand All @@ -28,7 +29,7 @@ func (a *APIStore) PutSandboxesSandboxIDNetwork(

team := auth.MustGetTeamInfo(c)

body, err := utils.ParseBody[api.PutSandboxesSandboxIDNetworkJSONBody](ctx, c)
body, err := ginutils.ParseBody[api.PutSandboxesSandboxIDNetworkJSONBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))
telemetry.ReportCriticalError(ctx, "error when parsing request", err)
Expand Down
3 changes: 2 additions & 1 deletion packages/api/internal/handlers/sandbox_refresh.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import (
"github.com/e2b-dev/infra/packages/api/internal/sandbox"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
)

Expand All @@ -31,7 +32,7 @@ func (a *APIStore) PostSandboxesSandboxIDRefreshes(
team := auth.MustGetTeamInfo(c)
var duration time.Duration

body, err := utils.ParseBody[api.PostSandboxesSandboxIDRefreshesJSONBody](ctx, c)
body, err := ginutils.ParseBody[api.PostSandboxesSandboxIDRefreshesJSONBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
3 changes: 2 additions & 1 deletion packages/api/internal/handlers/sandbox_resume.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import (
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
"github.com/e2b-dev/infra/packages/db/pkg/types"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/grpc/orchestrator"
"github.com/e2b-dev/infra/packages/shared/pkg/logger"
sbxlogger "github.com/e2b-dev/infra/packages/shared/pkg/logger/sandbox"
Expand All @@ -34,7 +35,7 @@ func (a *APIStore) PostSandboxesSandboxIDResume(c *gin.Context, sandboxID api.Sa

telemetry.ReportEvent(ctx, "Parsed body")

body, err := utils.ParseBody[api.PostSandboxesSandboxIDResumeJSONRequestBody](ctx, c)
body, err := ginutils.ParseBody[api.PostSandboxesSandboxIDResumeJSONRequestBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
3 changes: 2 additions & 1 deletion packages/api/internal/handlers/sandbox_timeout.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (
"github.com/e2b-dev/infra/packages/api/internal/api"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
)

Expand All @@ -31,7 +32,7 @@ func (a *APIStore) PostSandboxesSandboxIDTimeout(

var duration time.Duration

body, err := utils.ParseBody[api.PostSandboxesSandboxIDTimeoutJSONBody](ctx, c)
body, err := ginutils.ParseBody[api.PostSandboxesSandboxIDTimeoutJSONBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import (
"github.com/e2b-dev/infra/packages/api/internal/sandbox"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/auth"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/id"
"github.com/e2b-dev/infra/packages/shared/pkg/logger"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
Expand Down Expand Up @@ -44,7 +45,7 @@ func (a *APIStore) PostSandboxesSandboxIDSnapshots(c *gin.Context, sandboxID api
return
}

body, err := utils.ParseBody[api.PostSandboxesSandboxIDSnapshotsJSONRequestBody](ctx, c)
body, err := ginutils.ParseBody[api.PostSandboxesSandboxIDSnapshotsJSONRequestBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
4 changes: 2 additions & 2 deletions packages/api/internal/handlers/template_request_build_v3.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ import (
"github.com/e2b-dev/infra/packages/api/internal/api"
templatecache "github.com/e2b-dev/infra/packages/api/internal/cache/templates"
"github.com/e2b-dev/infra/packages/api/internal/template"
apiutils "github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/shared/pkg/clusters"
"github.com/e2b-dev/infra/packages/shared/pkg/featureflags"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/id"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
"github.com/e2b-dev/infra/packages/shared/pkg/templates"
Expand All @@ -24,7 +24,7 @@ import (
func (a *APIStore) PostV3Templates(c *gin.Context) {
ctx := c.Request.Context()

body, err := apiutils.ParseBody[api.TemplateBuildRequestV3](ctx, c)
body, err := ginutils.ParseBody[api.TemplateBuildRequestV3](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Invalid request body: %s", err))
telemetry.ReportCriticalError(ctx, "invalid request body", err)
Expand Down
4 changes: 2 additions & 2 deletions packages/api/internal/handlers/template_start_build_v2.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ import (
"go.uber.org/zap"

"github.com/e2b-dev/infra/packages/api/internal/api"
apiutils "github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/db/pkg/types"
"github.com/e2b-dev/infra/packages/db/queries"
"github.com/e2b-dev/infra/packages/shared/pkg/clusters"
"github.com/e2b-dev/infra/packages/shared/pkg/featureflags"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/logger"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
"github.com/e2b-dev/infra/packages/shared/pkg/templates"
Expand All @@ -40,7 +40,7 @@ type dockerfileStore struct {
func (a *APIStore) PostV2TemplatesTemplateIDBuildsBuildID(c *gin.Context, templateID api.TemplateID, buildID api.BuildID) {
ctx := c.Request.Context()

body, err := apiutils.ParseBody[api.TemplateBuildStartV2](ctx, c)
body, err := ginutils.ParseBody[api.TemplateBuildStartV2](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Invalid request body: %s", err))
telemetry.ReportCriticalError(ctx, "invalid request body", err)
Expand Down
6 changes: 3 additions & 3 deletions packages/api/internal/handlers/template_tags.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ import (

"github.com/e2b-dev/infra/packages/api/internal/api"
templatecache "github.com/e2b-dev/infra/packages/api/internal/cache/templates"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/db/pkg/dberrors"
"github.com/e2b-dev/infra/packages/db/queries"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/id"
"github.com/e2b-dev/infra/packages/shared/pkg/logger"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
Expand All @@ -24,7 +24,7 @@ import (
func (a *APIStore) PostTemplatesTags(c *gin.Context) {
ctx := c.Request.Context()

body, err := utils.ParseBody[api.AssignTemplateTagsRequest](ctx, c)
body, err := ginutils.ParseBody[api.AssignTemplateTagsRequest](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Invalid request body: %s", err))

Expand Down Expand Up @@ -179,7 +179,7 @@ func (a *APIStore) PostTemplatesTags(c *gin.Context) {
func (a *APIStore) DeleteTemplatesTags(c *gin.Context) {
ctx := c.Request.Context()

body, err := utils.ParseBody[api.DeleteTemplateTagsRequest](ctx, c)
body, err := ginutils.ParseBody[api.DeleteTemplateTagsRequest](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Invalid request body: %s", err))

Expand Down
4 changes: 2 additions & 2 deletions packages/api/internal/handlers/template_update.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ import (

"github.com/e2b-dev/infra/packages/api/internal/api"
templatecache "github.com/e2b-dev/infra/packages/api/internal/cache/templates"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/auth/pkg/types"
"github.com/e2b-dev/infra/packages/db/pkg/dberrors"
"github.com/e2b-dev/infra/packages/db/queries"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/id"
"github.com/e2b-dev/infra/packages/shared/pkg/logger"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
Expand Down Expand Up @@ -67,7 +67,7 @@ func (a *APIStore) PatchV2TemplatesTemplateID(c *gin.Context, aliasOrTemplateID
// updateTemplate contains the shared logic for updating a template.
// Returns the resolved team and aliasInfo on success, or an APIError on failure.
func (a *APIStore) updateTemplate(ctx context.Context, c *gin.Context, aliasOrTemplateID api.TemplateID, createBackwardCompatAlias bool) (*types.Team, *templatecache.AliasInfo, *api.APIError) {
body, err := utils.ParseBody[api.TemplateUpdateRequest](ctx, c)
body, err := ginutils.ParseBody[api.TemplateUpdateRequest](ctx, c)
if err != nil {
return nil, nil, &api.APIError{
Code: http.StatusBadRequest,
Expand Down
4 changes: 2 additions & 2 deletions packages/api/internal/handlers/volume_create.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ import (

"github.com/e2b-dev/infra/packages/api/internal/api"
"github.com/e2b-dev/infra/packages/api/internal/clusters"
"github.com/e2b-dev/infra/packages/api/internal/utils"
"github.com/e2b-dev/infra/packages/db/pkg/dberrors"
"github.com/e2b-dev/infra/packages/db/queries"
clustershared "github.com/e2b-dev/infra/packages/shared/pkg/clusters"
"github.com/e2b-dev/infra/packages/shared/pkg/featureflags"
"github.com/e2b-dev/infra/packages/shared/pkg/ginutils"
"github.com/e2b-dev/infra/packages/shared/pkg/grpc/orchestrator"
"github.com/e2b-dev/infra/packages/shared/pkg/telemetry"
)
Expand Down Expand Up @@ -44,7 +44,7 @@ func (a *APIStore) PostVolumes(c *gin.Context) {
}

// parse body
body, err := utils.ParseBody[api.PostVolumesJSONRequestBody](ctx, c)
body, err := ginutils.ParseBody[api.PostVolumesJSONRequestBody](ctx, c)
if err != nil {
a.sendAPIStoreError(c, http.StatusBadRequest, fmt.Sprintf("Error when parsing request: %s", err))

Expand Down
1 change: 1 addition & 0 deletions packages/dashboard-api/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ require (
github.com/sirupsen/logrus v1.9.3 // indirect
github.com/stretchr/testify v1.11.1 // indirect
github.com/testcontainers/testcontainers-go v0.40.0 // indirect
github.com/testcontainers/testcontainers-go/modules/postgres v0.39.0 // indirect
github.com/tklauser/go-sysconf v0.3.15 // indirect
github.com/tklauser/numcpus v0.10.0 // indirect
github.com/twitchyliquid64/golang-asm v0.15.1 // indirect
Expand Down
4 changes: 4 additions & 0 deletions packages/dashboard-api/go.sum

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading