(ctx context.Context, providerId string, start, end int64, apiIds ...string)
| 178 | } |
| 179 | |
| 180 | func (i *imlAPIUseService) SumByApis(ctx context.Context, providerId string, start, end int64, apiIds ...string) ([]*APIUse, error) { |
| 181 | //list, err := i.store.SumByGroup(ctx, "api", "api,sum(input_token) as input_token,sum(output_token) as output_token,sum(total_token) as total_token", "provider = ? and api in (?) and minute >= ? and minute <= ?", providerId, apiIds, start, end) |
| 182 | //if err != nil { |
| 183 | // return nil, err |
| 184 | //} |
| 185 | // |
| 186 | //return utils.SliceToSlice(list, func(v *api.AiAPIUse) *APIUse { |
| 187 | // return &APIUse{ |
| 188 | // API: v.API, |
| 189 | // InputToken: v.InputToken, |
| 190 | // OutputToken: v.OutputToken, |
| 191 | // TotalToken: v.TotalToken, |
| 192 | // } |
| 193 | //}), nil |
| 194 | return nil, nil |
| 195 | } |
nothing calls this directly
no outgoing calls
no test coverage detected