Search¶
This API allows search for apps by various properties.
Search¶
-
GET
/api/v2/apps/search/
¶ Request
Parameters: - q (string) – The query string to search for.
- cat (int|string) – The category slug to filter by. Use the category API to find the category slugs.
- dev (string) – Filters by supported device. One of ‘desktop’, ‘android’, or ‘firefoxos’.
- device (string) – Enables additional filtering by device profile if device is ‘android’. One of ‘mobile’ or ‘tablet’.
- pro (string) – A feature profile describing the features to filter by.
- premium_types (string) – Filters by whether the app is free or premium or has in-app purchasing. Any of ‘free’, ‘free-inapp’, ‘premium’, ‘premium-inapp’, or ‘other’ [1].
- app_type (string) – Filters by types of web apps. Any of ‘hosted’, ‘packaged’, or ‘privileged’.
- manifest_url (string) – Filters by manifest URL. Requires an exact match and should only return a single result if a match is found.
- installs_allowed_from – Filters apps by the manifest ‘installs_allowed_from’ field. The only supported value is ‘*’.
- offline (string) – Filters by whether the app works offline or not. ‘True’ to show offline-capable apps; ‘False’ to show apps requiring online support; any other value will show all apps unfiltered by offline support.
- languages (string) – Filters apps by a supported language. Language codes should be provided in ISO 639-1 format, using a comma-separated list if supplying multiple languages.
- author (string) – Filters by author. Requires a case-insensitive exact match of the author field.
- region (string) – Filters apps by a supported region. A region code should be provided in ISO 3166 format (e.g., pl). In API v1 (and only v1), if not provided, the region is automatically detected via requesting IP address. To disable automatic region detection, None may be passed.
- guid (string) – Filter for a specific app by Marketplace GUID.
- sort (string) – The fields to sort by. One or more of ‘created’, ‘downloads’, ‘name’, ‘rating’, ‘reviewed’, or ‘trending’. Sorts by relevance by default. In every case except ‘name’, sorting is done in descending order.
Response
Parameters: - meta (object) – Listing response meta.
- objects (array) – A listing of apps, with the following additional fields:
{ "absolute_url": https://marketplace.firefox.com/app/my-app/", }
Status Codes: - 200 OK – successfully completed.
Multi-Search¶
This API allows search for mixed content by various properties. Content types include webapps and websites.
-
GET
/api/v2/multi-search/
¶ Parameters: - doc_type (optionnal) (string) – The type of content to search for,
separated by a comma (without spaces). Defaults to
webapp,website
if absent or invalid. Supported content types:webapp
,website
andextension
.
Response
Similar to Search API but the
objects
field can contain:- Apps if
doc_type
includeswebapp
; - Websites if
doc_type
includeswebsite
; - Firefox OS Add-ons if
doc_type
includesextension
.
- doc_type (optionnal) (string) – The type of content to search for,
separated by a comma (without spaces). Defaults to
Feature Profile Signatures¶
Feature profile signatures indicate what features a device supports or does not support, so the search results can exclude apps that require features your device doesn’t provide.
The format of a signature is FEATURES.SIZE.VERSION, where FEATURES is a bitfield in hexadecimal, SIZE is its length in bits as a decimal number, and VERSION is a decimal number indicating the version of the features table.
Each bit in the features bitfield represents the presence or absence of a feature. New features will always be added as the least significant bit.
Feature table version 8:
bit position | feature |
---|---|
0 | UDP Sockets |
1 | OpenMobile ACL |
2 | NFC |
3 | 1GB RAM Device |
4 | 512MB RAM Device |
5 | Asm.js Precompilation |
6 | Mobile ID |
7 | Multiple Network Information |
8 | Third-Party Keyboard Support |
9 | TCP Sockets |
10 | SystemXHR |
11 | Alarms |
12 | Notifications |
13 | Pointer Lock |
14 | Web Speech Recognition |
15 | Web Speech Synthesis |
16 | WebRTC PeerConnection |
17 | WebRTC DataChannel |
18 | WebRTC MediaStream |
19 | Screen Capture |
20 | Microphone |
21 | Camera |
22 | Quota Management |
23 | Gamepad |
24 | Full Screen |
25 | WebM |
26 | H.264 |
27 | Web Audio |
28 | Audio |
29 | MP3 |
30 | Smartphone-Sized Displays (qHD) |
31 | Touch |
32 | WebSMS |
33 | WebFM |
34 | Vibration |
35 | Time/Clock |
36 | Screen Orientation |
37 | Simple Push |
38 | Proximity |
39 | Network Stats |
40 | Network Information |
41 | Idle |
42 | Geolocation |
43 | IndexedDB |
44 | Device Storage |
45 | Contacts |
46 | Bluetooth |
47 | Battery |
48 | Archive |
49 | Ambient Light Sensor |
50 | Web Activities |
51 | Web Payment |
52 | Packaged Apps Install API |
53 | App Management API |
For example, a device with only the ‘App Management API’, ‘Proximity’, ‘Ambient Light Sensor’, and ‘Vibration’ features enabled would send this feature profile signature:
11002200000000.53.8
[1] | other denotes a payment system other than the Firefox Marketplace payments. This field is not currently populated by the Marketplace Developer Hub. |