modify query api