Hello Morten,

first of all I forgot to mention that we are using version 2.21.

Yes, we tried sending the zip file, but no success. The server response was:

{
  "responseType": "ImportSummary",
  "status": "ERROR",
  "description": "The import process failed: Unrecognized token
'PK\u0003\u0004': was expecting ('true', 'false' or 'null')\n at [Source:
org.apache.catalina.connector.CoyoteInputStream@bdd767e; line: 1, column:
6]",
  "importCount": {
    "imported": 0,
    "updated": 0,
    "ignored": 0,
    "deleted": 0
  }
}

Regards,

Victor

On 28 July 2016 at 11:23, Morten Olav Hansen <mor...@dhis2.org> wrote:

> Hi
>
> Did you try and simply send the data as a zipped file? I think we support
> both gzip and zip, you don't need to do anything else than zip it down
> before.
>
> I'm not 100% sure it will work, but this is how our metadata endpoints
> work.
>
> --
> Morten Olav Hansen
> Senior Engineer, DHIS 2
> University of Oslo
> http://www.dhis2.org
>
> On Thu, Jul 28, 2016 at 11:12 AM, Victor Garcia <vgarcia...@gmail.com>
> wrote:
>
>> Hi all,
>>
>> searching in the documentation I couldn't find a way to import a data
>> file in zip format through the API. I know it is possible to do it using
>> the user interface (import/export module), but we need to use the API. Is
>> it supported?
>>
>> This problem arises in contexts with a poor connection, where large data
>> exchanges are a pain.
>>
>> Thank you,
>>
>> VĂ­ctor
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to     : dhis2-devs@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
_______________________________________________
Mailing list: https://launchpad.net/~dhis2-devs
Post to     : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp

Reply via email to