You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
spa_instat_tv/src/requests/getUserSubscriptions.tsx

38 lines
573 B

import {
DATA_URL,
PROCEDURES,
} from 'config'
import { callApi } from 'helpers'
const proc = PROCEDURES.get_user_subscriptions
type Team = {
id: number,
name_eng: string,
name_rus: string,
}
type CustomSubscription = {
sport: number,
teams: Array<Team>,
}
type UserSubscription = {
custom: Array<CustomSubscription>,
id: number,
lexic: number,
}
export const getUserSubscriptions = (): Promise<UserSubscription> => {
const config = {
body: {
params: {},
proc,
},
}
return callApi({
config,
url: DATA_URL,
})
}