Release 1.2.0

master
Ilya 8 years ago
parent 569711b576
commit e6e0eed6e4

@ -1,4 +1,4 @@
# Ambar Web API v0.9.5 # Ambar Web API v1.2.0
Ambar Web API documentation Ambar Web API documentation
@ -14,7 +14,8 @@ Ambar Web API documentation
- [Search](#search) - [Search](#search)
- [Search For Documents By Query](#search-for-documents-by-query) - [Search For Documents By Query](#search-for-documents-by-query)
- [Retrieve File Highlight by Query and SHA](#retrieve-file-highlight-by-query-and-sha) - [Retrieve File Highlight by Query and fileId](#retrieve-file-highlight-by-query-and-fileid)
- [Retrieve Full File Highlight by Query and fileId](#retrieve-full-file-highlight-by-query-and-fileid)
- [Sources](#sources) - [Sources](#sources)
- [Get Available Sources](#get-available-sources) - [Get Available Sources](#get-available-sources)
@ -164,9 +165,9 @@ File meta or content not found
``` ```
## Upload File ## Upload File
<p>New source with description <code>Automatically created on UI upload</code> will be created if source didn't exist.</p> <p>New source named <code>uiupload</code> with description <code>Automatically created on UI upload</code> will be created if source didn't exist.</p>
POST api/files/:sourceId/:filename POST api/files/uiupload/:filename
### Headers ### Headers
@ -181,7 +182,7 @@ Upload File test.txt
``` ```
curl -X POST \ curl -X POST \
http://ambar_api_address/api/files/Default/test.txt \ http://ambar_api_address/api/files/uiupload/test.txt \
-H 'content-type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW' \ -H 'content-type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW' \
-F file=@test.txt -F file=@test.txt
``` ```
@ -351,11 +352,11 @@ HTTP/1.1 400 BadRequest
``` ```
HTTP/1.1 400 BadRequest HTTP/1.1 400 BadRequest
``` ```
## Retrieve File Highlight by Query and SHA ## Retrieve File Highlight by Query and fileId
<p>This method is useful for getting higlights of large files &gt; 30 MB</p> <p>This method is useful for getting higlights of large files &gt; 30 MB</p>
GET api/search/:sha GET api/search/:fileId
### Headers ### Headers
@ -368,12 +369,12 @@ HTTP/1.1 400 BadRequest
| Name | Type | Description | | Name | Type | Description |
|---------|-----------|--------------------------------------| |---------|-----------|--------------------------------------|
| sha | String | <p>file SHA</p> | | fileId | String | <p>file fileId</p> |
| query | String | <p>query string</p> | | query | String | <p>query string</p> |
### Examples ### Examples
Retrieve Higlights for File with SHA `318be2290125e0a6cfb7229133ba3c4632068ae04942ed5c7c660718d9d41eb3` Retrieve Higlights for File with fileId `318be2290125e0a6cfb7229133ba3c4632068ae04942ed5c7c660718d9d41eb3`
``` ```
curl -i http://ambar:8004/api/search/318be2290125e0a6cfb7229133ba3c4632068ae04942ed5c7c660718d9d41eb3?query=John curl -i http://ambar:8004/api/search/318be2290125e0a6cfb7229133ba3c4632068ae04942ed5c7c660718d9d41eb3?query=John
@ -396,6 +397,48 @@ HTTP/1.1 200 OK
HTTP/1.1 400 BadRequest HTTP/1.1 400 BadRequest
```
HTTP/1.1 400 BadRequest
```
## Retrieve Full File Highlight by Query and fileId
<p>This method is useful for getting higlights of large files &gt; 30 MB</p>
GET api/search/:fileId/full
### Headers
| Name | Type | Description |
|---------|-----------|--------------------------------------|
| ambar-email | String | <p>User email.</p> |
| ambar-email-token | String | <p>User token.</p> |
### Parameters
| Name | Type | Description |
|---------|-----------|--------------------------------------|
| fileId | String | <p>file fileId</p> |
| query | String | <p>query string</p> |
### Examples
Retrieve Full Higlight for File with fileId `318be2290125e0a6cfb7229133ba3c4632068ae04942ed5c7c660718d9d41eb3`
```
curl -i http://ambar:8004/api/search/318be2290125e0a6cfb7229133ba3c4632068ae04942ed5c7c660718d9d41eb3/full?query=John
```
### Success Response
HTTP/1.1 200 OK
```
Aesop, by some strange accident it seems to have entirely<br/>disappeared, and to have been lost sight of. His name is<br/>mentioned by Avienus; by Suidas, a celebrated critic, at the<br/>close of the eleventh century, who gives in his lexicon several<br/>isolated verses of his version of the fables; and by <em>John</em><br/>Tzetzes, a grammarian and poet of Constantinople, who lived<br/>during the latter half of the twelfth century. Nevelet, in the<br/>preface to the volume which we have described, points out that<br/>the Fables of Planudes could not be the work of Aesop, as they<br/>contain a reference in two places to Holy
```
### Error Response
HTTP/1.1 400 BadRequest
``` ```
HTTP/1.1 400 BadRequest HTTP/1.1 400 BadRequest
``` ```
@ -507,7 +550,7 @@ HTTP/1.1 200 OK
DELETE api/tags/:fileId/:tagName DELETE api/tags/:fileId/:tagType/:tagName
### Headers ### Headers
@ -521,6 +564,7 @@ HTTP/1.1 200 OK
| Name | Type | Description | | Name | Type | Description |
|---------|-----------|--------------------------------------| |---------|-----------|--------------------------------------|
| fileId | String | <p>File Id to delete tag from.</p> | | fileId | String | <p>File Id to delete tag from.</p> |
| tagType | String | <p>Tag type to delete.</p> |
| tagName | String | <p>Tag name to delete.</p> | | tagName | String | <p>Tag name to delete.</p> |
### Success Response ### Success Response
@ -582,7 +626,7 @@ HTTP/1.1 200 OK
POST api/tags/:fileId/:tagName POST api/tags/:fileId/:tagType/:tagName
### Headers ### Headers
@ -596,6 +640,7 @@ HTTP/1.1 200 OK
| Name | Type | Description | | Name | Type | Description |
|---------|-----------|--------------------------------------| |---------|-----------|--------------------------------------|
| fileId | String | <p>File Id to add tag to.</p> | | fileId | String | <p>File Id to add tag to.</p> |
| tagType | String | <p>Tag type to add.</p> |
| tagName | String | <p>Tag name to add.</p> | | tagName | String | <p>Tag name to add.</p> |
### Success Response ### Success Response

@ -1,6 +1,23 @@
Change log Change log
========== ==========
1.2.0 (2017-10-18)
-------------------
Hello everyone!
Ambar 1.2.0 is out!
### What's new?
- Now you can preview any file in Ambar
- If file contains some sensible data like emails, tax ids, vehicle ids, etc - Ambar recognizes and highlights them. We call this sensible data "named entities".
- You can search by named entities using query `entitites:"hello@ambar.cloud"`
- We added tags coloring depending on tag's type
Before updating your Ambar to this version, you need to reset all the data in your Ambar with `sudo ./ambar.py reset`. After reset run `sudo ./ambar.py update` to get the latest version.
1.1.0 (2017-09-07) 1.1.0 (2017-09-07)
------------------- -------------------

@ -1 +1 @@
Subproject commit 96bbfff40d77c1de5733ec1144060ab6460ef028 Subproject commit f257f6e8221ac2dd2b28ab80175688c297d8a986

@ -1 +1 @@
Subproject commit 97274039a0c95e56f098fa7759017ca64401524c Subproject commit c475e4919d55ab6f65a4f9c10204229b54150f9c

@ -1 +1 @@
Subproject commit 2589f70fc25647c1b7dc23cc2bbc112191967dc0 Subproject commit 9539740dd215d73958e2c14f7cbe745a263cae7a

@ -1,4 +1,4 @@
[![Version](https://img.shields.io/badge/Version-v1.0.0-brightgreen.svg)](https://ambar.cloud) [![Version](https://img.shields.io/badge/Version-v1.2.0-brightgreen.svg)](https://ambar.cloud)
[![License](https://img.shields.io/badge/License-Fair%20Source%20v0.9-blue.svg)](https://github.com/RD17/ambar/blob/master/License.txt) [![License](https://img.shields.io/badge/License-Fair%20Source%20v0.9-blue.svg)](https://github.com/RD17/ambar/blob/master/License.txt)
[![Blog](https://img.shields.io/badge/Ambar%20Blog-%20Latest%20news%20and%20tutorials%20-brightgreen.svg)](https://blog.ambar.cloud) [![Blog](https://img.shields.io/badge/Ambar%20Blog-%20Latest%20news%20and%20tutorials%20-brightgreen.svg)](https://blog.ambar.cloud)
@ -14,6 +14,7 @@ Ambar defines the new way to manage your documents out of the box:
- Ingest documents from any source - Ingest documents from any source
- Find documents and images instantly with Google-like search - Find documents and images instantly with Google-like search
- Manage your documents with tags, hide irrelevant search results - Manage your documents with tags, hide irrelevant search results
- Auto tagging & named entitites recognition
- Download or share links to your documents, even if they've been deleted from the source - Download or share links to your documents, even if they've been deleted from the source
## Features ## Features

Loading…
Cancel
Save