@@ -7,15 +7,12 @@ import (
7
7
"errors"
8
8
"fmt"
9
9
"net/http"
10
- "net/url"
11
10
"time"
12
11
13
12
"github.com/cloudflare/cloudflare-go/v4/internal/apijson"
14
- "github.com/cloudflare/cloudflare-go/v4/internal/apiquery"
15
13
"github.com/cloudflare/cloudflare-go/v4/internal/param"
16
14
"github.com/cloudflare/cloudflare-go/v4/internal/requestconfig"
17
15
"github.com/cloudflare/cloudflare-go/v4/option"
18
- "github.com/cloudflare/cloudflare-go/v4/packages/pagination"
19
16
)
20
17
21
18
// WaitingRoomService contains methods and other services that help with
@@ -85,33 +82,6 @@ func (r *WaitingRoomService) Update(ctx context.Context, waitingRoomID string, p
85
82
return
86
83
}
87
84
88
- // Lists waiting rooms.
89
- func (r * WaitingRoomService ) List (ctx context.Context , params WaitingRoomListParams , opts ... option.RequestOption ) (res * pagination.V4PagePaginationArray [WaitingRoom ], err error ) {
90
- var raw * http.Response
91
- opts = append (r .Options [:], opts ... )
92
- opts = append ([]option.RequestOption {option .WithResponseInto (& raw )}, opts ... )
93
- if params .ZoneID .Value == "" {
94
- err = errors .New ("missing required zone_id parameter" )
95
- return
96
- }
97
- path := fmt .Sprintf ("zones/%s/waiting_rooms" , params .ZoneID )
98
- cfg , err := requestconfig .NewRequestConfig (ctx , http .MethodGet , path , params , & res , opts ... )
99
- if err != nil {
100
- return nil , err
101
- }
102
- err = cfg .Execute ()
103
- if err != nil {
104
- return nil , err
105
- }
106
- res .SetPageConfig (cfg , raw )
107
- return res , nil
108
- }
109
-
110
- // Lists waiting rooms.
111
- func (r * WaitingRoomService ) ListAutoPaging (ctx context.Context , params WaitingRoomListParams , opts ... option.RequestOption ) * pagination.V4PagePaginationArrayAutoPager [WaitingRoom ] {
112
- return pagination .NewV4PagePaginationArrayAutoPager (r .List (ctx , params , opts ... ))
113
- }
114
-
115
85
// Deletes a waiting room.
116
86
func (r * WaitingRoomService ) Delete (ctx context.Context , waitingRoomID string , body WaitingRoomDeleteParams , opts ... option.RequestOption ) (res * WaitingRoomDeleteResponse , err error ) {
117
87
var env WaitingRoomDeleteResponseEnvelope
@@ -1335,23 +1305,6 @@ func (r waitingRoomUpdateResponseEnvelopeJSON) RawJSON() string {
1335
1305
return r .raw
1336
1306
}
1337
1307
1338
- type WaitingRoomListParams struct {
1339
- // Identifier
1340
- ZoneID param.Field [string ] `path:"zone_id,required"`
1341
- // Page number of paginated results.
1342
- Page param.Field [float64 ] `query:"page"`
1343
- // Maximum number of results per page. Must be a multiple of 5.
1344
- PerPage param.Field [float64 ] `query:"per_page"`
1345
- }
1346
-
1347
- // URLQuery serializes [WaitingRoomListParams]'s query parameters as `url.Values`.
1348
- func (r WaitingRoomListParams ) URLQuery () (v url.Values ) {
1349
- return apiquery .MarshalWithSettings (r , apiquery.QuerySettings {
1350
- ArrayFormat : apiquery .ArrayQueryFormatRepeat ,
1351
- NestedFormat : apiquery .NestedQueryFormatDots ,
1352
- })
1353
- }
1354
-
1355
1308
type WaitingRoomDeleteParams struct {
1356
1309
// Identifier
1357
1310
ZoneID param.Field [string ] `path:"zone_id,required"`
0 commit comments