code: func (s *Service) CreateBucket(ctx context.Context, b *platform.Bucket) error {
  	if b.OrganizationID.Valid() {
  		_, pe := s.FindOrganizationByID(ctx, b.OrganizationID)
  		if pe != nil {
  			return &platform.Error{
  				Err: pe,
  				Op:  OpPrefix + platform.OpCreateBucket,
  			}
  		}
  	} else {
  		o, pe := s.findOrganizationByName(ctx, b.Organization)
  		if pe != nil {
  			return &platform.Error{
  				Err: pe,
  				Op:  OpPrefix + platform.OpCreateBucket,
  			}
  		}
  		b.OrganizationID = o.ID
  	}
  	filter := platform.BucketFilter{
  		Name:           &b.Name,
  		OrganizationID: &b.OrganizationID,
  	}
  	if _, err := s.FindBucket(ctx, filter); err == nil {
  		return &platform.Error{
  			Code: platform.EConflict,
  			Op:   OpPrefix + platform.OpCreateBucket,
  			Msg:  fmt.Sprintf("bucket with name %s already exists", b.Name),
  		}
  	}
  	b.ID = s.IDGenerator.ID()
  	return s.PutBucket(ctx, b)
  }
docs: // CreateBucket creates a new bucket and sets b.ID with the new identifier.