mirror of
https://github.com/nolanlawson/pinafore
synced 2024-12-14 11:27:45 +01:00
11 lines
323 B
JavaScript
11 lines
323 B
JavaScript
import { getWithTimeout, paramsString } from '../_utils/ajax'
|
|
import { auth, basename } from './utils'
|
|
|
|
export function search (instanceName, accessToken, query) {
|
|
let url = `${basename(instanceName)}/api/v1/search?` + paramsString({
|
|
q: query,
|
|
resolve: true
|
|
})
|
|
return getWithTimeout(url, auth(accessToken))
|
|
}
|