(projectKey: string, environmentKey: string, toggleKey: string)
| 37 | }; |
| 38 | |
| 39 | export const getTargeting = async<T> (projectKey: string, environmentKey: string, toggleKey: string) => { |
| 40 | const url = `${ |
| 41 | API.targetingURI |
| 42 | .replace(':projectKey', projectKey) |
| 43 | .replace(':environmentKey', environmentKey) |
| 44 | .replace(':toggleKey', toggleKey) |
| 45 | }`; |
| 46 | |
| 47 | return request<T>(url, { |
| 48 | method: 'GET', |
| 49 | headers: { |
| 50 | ...ApplicationJson() |
| 51 | }, |
| 52 | }); |
| 53 | }; |
| 54 | |
| 55 | export const saveToggle = async (projectKey: string, environmentKey: string, toggleKey: string, data: ITargetingParams) => { |
| 56 | const url = `${ |
no test coverage detected