You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: services.go
    path of file: ./repos/portainer/api/http/proxy/factory/docker
    
    the code of the file until where you have to start completion: package docker

import (
	"bytes"
	"context"
	"errors"
	"io"
	"net/http"

	portainer "github.com/portainer/portainer/api"
	"github.com/portainer/portainer/api/http/proxy/factory/utils"
	"github.com/portainer/portainer/api/internal/authorization"

	"github.com/docker/docker/api/types"
	"github.com/docker/docker/client"
	"github.com/segmentio/encoding/json"
)

const serviceObjectIdentifier = "ID"

func getInheritedR
    
func (transport *Transport) decorateServiceCreationOperation(request *http.Request) (*http.Response, error) {
	type PartialService struct {
		TaskTemplate struct {
			ContainerSpec struct {
				Mounts []struct {
					Type string
				}
			}
		}
	}

	forbiddenResponse := &http.Response{
		StatusCode: http.StatusForbidden,
	}

	isAdminOrEndpointAdmin, err := transport.isAdminOrEndpointAdmin(request)
	if err != nil {
		return nil, err
	}

	if !isAdminOrEndpointAdmin {
		securitySettings, err := transport.fetchEndpointSecuritySettings()
		if err != nil {
			return nil, err
		}

		body, err := io.ReadAll(request.Body)
		if err != nil {
			return nil, err
		}

		partialService := &PartialService{}
		err = json.Unmarshal(body, partialService)
		if err != nil {
			return nil, err
		}

		if !securitySettings.AllowBindMountsForRegularUsers && (len(partialService.TaskTemplate.ContainerSpec.Mounts) > 0) {
			for _, mount := range partialService.TaskTemplate.ContainerSpec.Mounts {
				if mount.Type == "bind" {
					return forbiddenResponse, errors.New("forbidden to use bind mounts")
				}
			}
		}

		request.Body = io.NopCloser(bytes.NewBuffer(body))
	}

	return transport.replaceRegistryAuthenticationHeader(request)
}