(projectKey: string, environmentKey: string, toggleKey: string, params: ITrafficParams)
| 177 | }; |
| 178 | |
| 179 | export const getTraffic = async<T> (projectKey: string, environmentKey: string, toggleKey: string, params: ITrafficParams) => { |
| 180 | const url = `${ |
| 181 | API.trafficURI |
| 182 | .replace(':projectKey', projectKey) |
| 183 | .replace(':environmentKey', environmentKey) |
| 184 | .replace(':toggleKey', toggleKey) |
| 185 | }?${qs.stringify(params)}`; |
| 186 | |
| 187 | return request<T>(url, { |
| 188 | method: 'GET', |
| 189 | headers: { |
| 190 | ...ApplicationJson() |
| 191 | }, |
| 192 | }); |
| 193 | }; |
| 194 | |
| 195 | export const checkToggleExist = async<T> (projectKey: string, params: IExistParams) => { |
| 196 | const url = `${ |
no test coverage detected