feedhenry / fh-fhc

FeedHenry CLI, the Command Line Interface to FeedHenry
Other
26 stars 66 forks source link

FH-3750 - Change the cmd fhc admin-storeitems to follow the V3 standard and add unit tests #399

Closed camilamacedo86 closed 7 years ago

camilamacedo86 commented 7 years ago

JIRA: https://issues.jboss.org/browse/FH-3750

Changes performed

Steps to Verify Thes commands are to manage the items into the App Store. To check this area into the studio go to Admin >> Mobile App Management >> App Store Apps.

To List:

Local Tests To List:

To Read:

screen shot 2017-08-13 at 12 41 35 pm

To Create:

Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems create --name=NewTest --description=DescTest 
Store Item created successfully.
Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems create --name=NewTest --description=DescTest --json
fhc ERR! Error creating storeitem: An item with the name NewTest cannot be created as it already exists
Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems create --name=NewTest1 --description=DescTest --json
{
  "authToken": "",
  "authpolicies": [],
  "binaries": [],
  "description": "DescTest",
  "groups": [],
  "guid": "w2oibpdjmo7dsavum63mn4k7",
  "icon": "",
  "name": "NewTest1",
  "notes": "",
  "requirements": "",
  "restrictToGroups": false,
  "screenshots": [],
  "status": "ok",
  "version": "",
  "whatsNew": ""
}

To Delete:

Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems delete r33ulbcz2cqf2w7xps7ilkxd
Item Store deleted successfully.
Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems delete w2oibpdjmo7dsavum63mn4k7 --json
{
  "status": "ok"
}
Camilas-MacBook-Pro:fh-fhc cmacedo$ 

To Update:

screen shot 2017-08-13 at 12 49 30 pm

To Upload: Icon:

Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems uploadicon --id=z46kp2hxkle4m66pcf3wc6ix --icon=iconTest.jpg 
{"authToken":"xpzaqtip2ctewg3hudhiyeuv","authpolicies":[],"binaries":[],"description":"DescTestUpda","groups":[],"guid":"z46kp2hxkle4m66pcf3wc6ix","icon":"iVBORw0KGgoAAAANSUhEUgAAASYAAACrCAMAAAD8Q8FaAAABIFBMVEX///8AAADkT2slytAmz9WKiorpUW3S0tLb29vCwsIeo6cYhIeUM0W4QFZSUlIhtLrLRl9KICgZi48XfIBfIS1XHikbkZUOTlCkOU0jwMbZS2YmDRIGIyMEAQJ4KjkUam2ILz8QWl0JMjMoKCgEFhcLPj8YJCPLy8sXFxcQEBAqKioiIiIAIh7jQWEmWVsmHx57NUI1NTX0vca1tbX98vQmGRic5OeNOkgUJCItDxXD7vCdnZ3n5+fvoK1TLTMbCQ1AKi54eHj52+DqfpAldXn86ewcm588FRx4UlmyPlRHIihjSk6rq6t8KzomCARU0tcmNDXr+vp729/mWnTpdornaH/umKfztsBpMjva9fb2zNO77e+YmJhlZWVBQUEmPj9cfAKaAAAI4UlEQVR4nO2deV/aSBiAJUmDVShUlCPl0Ea5IlJbsdrD4lFddz16aNG6rd//W2xukpCZhJAZpsv7/LGd7W+Krw/vO5nMDGFuDgAAAAAAAAAAAJhVvt6rfJ12FDh2jlQ+TzOCrw/XvM71t3fTjAPNzuDmu9jpdLjbH0fTimGXd3DNoKidj1yHM+l0bqYi6v6ad/NtGlHgOPpuSzJMfaQfwzt+hGv6UeB4LXIeOse0Y7i35QiCwKSnn3oqiSbT8fR1mEP5fL5ktXfpRoHjsyHm7qAty/27opVPA6pBfLNzaeGqd3Vq59M91ShwHOtapHq9vrm5uVc+sDzRnBo4Su6kJ3e32Cs7o+Q4Sa7fiWL2rr73yqw7mmX3bajpi9KVr4YlyEo6GcnESUpd9SOK/XqffjoNRyZhodc96faGVcfIrMAcmUxNnHhX70vURydXzV3xXfaqzqw5K5vU2juwpgf0qs4x/f6iKtrq9uxrHc/G/d1HpyYp3a8rWUvT9x1aQTiuc91eXjjtqf9hS9OxXXSyeqUr1/u2Ja4zBU1qzamJdOWoOsY0yeqs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J9NUufYXs/z0Y6Lac9wxoD77n4Czy2O/JxDZNoEiUsnou/yGF7c1FPy5EAHiUDmkATaAJNoAk0gSbQFFJTLI8HZUBTjaymGJ4XfkZWUzFI0wdF67E09gdSxsB4xlgDEwQW40v8VmN+qpyLtH4OCnvO8dD/3jlu8N/+huW98QoVYhivv41/s+homuTbMxUqEb7BB/GURgwB30yJh8ozzZ8ERdGQSYfQijx+m57If8domPfxzeEzghwGpHMYnv71nBx///N+km9ABQAAAAAAAAAAAAAAAAAAoMl/Z3M7KVQ5sf0AAAAASUVORK5CYII=","name":"TestUpdate","notes":"","requirements":"","restrictToGroups":true,"screenshots":[],"status":"ok","support":{},"version":"","whatsNew":""}
screen shot 2017-08-13 at 12 56 15 pm

Binary:

Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems uploadbinary --id=z46kp2hxkle4m66pcf3wc6ix --type=android --binary=test.txt 
{"authToken":"xpzaqtip2ctewg3hudhiyeuv","authpolicies":[],"binaries":[{"config":{},"storeItemBinaryVersion":1,"sysModified":"Sun Aug 13 11:59:52 UTC 2017","type":"android","url":"https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=kojb7crewzfzdrqizf3horv6","versions":[]}],"description":"DescTestUpda","groups":[],"guid":"z46kp2hxkle4m66pcf3wc6ix","icon":"iVBORw0KGgoAAAANSUhEUgAAASYAAACrCAMAAAD8Q8FaAAABIFBMVEX///8AAADkT2slytAmz9WKiorpUW3S0tLb29vCwsIeo6cYhIeUM0W4QFZSUlIhtLrLRl9KICgZi48XfIBfIS1XHikbkZUOTlCkOU0jwMbZS2YmDRIGIyMEAQJ4KjkUam2ILz8QWl0JMjMoKCgEFhcLPj8YJCPLy8sXFxcQEBAqKioiIiIAIh7jQWEmWVsmHx57NUI1NTX0vca1tbX98vQmGRic5OeNOkgUJCItDxXD7vCdnZ3n5+fvoK1TLTMbCQ1AKi54eHj52+DqfpAldXn86ewcm588FRx4UlmyPlRHIihjSk6rq6t8K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RpqKshfNCKZbh2yQjBGaTK4WS/p7cG1BSHMO3hf0Bn3G3M+OYDNiTAj5IU8Ozh9L0W/f1bGfGMhmw4CJqIgF2Wc69O9CURxYvWdz1paopOboJpf4VdpF3BjX5bxkkRhbDZ1uTKsR3AyrhzaeZ1tSItJ05a5oibo7PmKaG76V/6Al11GK2NEU/uDNLmp4qWEseTyxqwj7sxHu6QChhuyM1XbQQiwEOT23EaTlOwj7txPv743tL0W5WSgX8nWLNrWkR33sjg9A0dxF4RDWJKroq/mcuSy5L55+wvV+kIx0Dy+FjSCTyzuoMXE8ooDSNhWshpRj0M1ed1SnhLSUS+1GyKXhZzjmIGY8ewBF2LXwMTYHLclWnpmxQb0Krl3+YJimod3RNrZo/a/6aCojuZYKali+rvlR8NZ359748m0gTagMq469pEbHYNM4G1LiaEBtQ+kg0qqlKZgPKfzvTkDKqCTXlIqkJsZ2Z9c+mqn9v0ASaQBNoAk2gCTSBJtAEmhjShLhZQWry3xifws0KUhOJm5UE4iOpG/6aXiK6rxPU9BzxmdSR3NE17SN6v5hMEw5YSPk/aiK0LBe4yHs61iLvWvyaAhd5U65sCjo0FmmRl+fXylhyvBPh9CW2d6EUuyaOW32B5dJ9NUufYXs/z0Y6Lac9wxoD77n4Czy2O/JxDZNoEiUsnou/yGF7c1FPy5EAHiUDmkATaAJNoAk0gSbQFFJTLI8HZUBTjaymGJ4XfkZWUzFI0wdF67E09gdSxsB4xlgDEwQW40v8VmN+qpyLtH4OCnvO8dD/3jlu8N/+huW98QoVYhivv41/s+homuTbMxUqEb7BB/GURgwB30yJh8ozzZ8ERdGQSYfQijx+m57If8domPfxzeEzghwGpHMYnv71nBx///N+km9ABQAAAAAAAAAAAAAAAAAAoMl/Z3M7KVQ5sf0AAAAASUVORK5CYII=","name":"TestUpdate","notes":"","requirements":"","restrictToGroups":true,"screenshots":[],"status":"ok","support":{},"version":"","whatsNew":""}
Camilas-MacBook-Pro:fh-fhc cmacedo$ 
screen shot 2017-08-13 at 1 00 35 pm

To manage policies of the item store

Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems listpolicies z46kp2hxkle4m66pcf3wc6ix
{
  "count": 4,
  "list": [
    "xpzaqtip2ctewg3hudhiyeuv",
    "vv222fn3y7n4yayaaiz2fnoi",
    "n27tviknp56zo44gn2pvmpuc",
    "buz3uzepozxtq4tpudksw52n"
  ],
  "status": "ok"
}
screen shot 2017-08-13 at 1 33 59 pm

-- del:

screen shot 2017-08-13 at 1 36 41 pm

To manage grups of the item store

Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems addgroups fsresasbhhfva5pyvzgatstp 64oj7wsmt5toh46rl3ni2ltz
{
  "authToken": "",
  "authpolicies": [],
  "binaries": [
    {
      "config": {},
      "storeItemBinaryVersion": 3,
      "sysModified": "Wed May 24 20:57:57 UTC 2017",
      "type": "android",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe",
      "versions": [
        {
          "config": {},
          "destinationCode": "android",
          "storeItemBinaryGuid": "3uxxmivxsi7njnbxfikxgefe",
          "storeItemBinaryModified": "Fri Jul 31 13:35:33 UTC 2015",
          "storeItemBinaryVersion": 2,
          "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe&binversGuid=in52m66luesx7bgrjcchsevw&download=true"
        },
        {
          "config": {},
          "destinationCode": "android",
          "storeItemBinaryGuid": "3uxxmivxsi7njnbxfikxgefe",
          "storeItemBinaryModified": "Fri Jul 31 13:35:17 UTC 2015",
          "storeItemBinaryVersion": 1,
          "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe&binversGuid=btmerdcc3invb46s2p4miovk&download=true"
        }
      ]
    },
    {
      "config": {},
      "storeItemBinaryVersion": 1,
      "sysModified": "Mon Aug 24 19:08:12 UTC 2015",
      "type": "ios",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=oe5rdqmzkmwyzvqdjm3aqhqw",
      "versions": []
    },
    {
      "config": {},
      "storeItemBinaryVersion": 1,
      "sysModified": "Tue Sep 27 15:46:47 UTC 2016",
      "type": "iphone",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=tc6fwvqm6rom24msk3of2ctr",
      "versions": []
    }
  ],
  "description": "",
  "groups": [
    "64oj7wsmt5toh46rl3ni2ltz"
  ],
  "guid": "fsresasbhhfva5pyvzgatstp",
  "icon": "",
  "name": "sp-test",
  "restrictToGroups": false,
  "screenshots": [],
  "status": "ok",
  "support": {},
  "version": ""
}
Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems addgroups fsresasbhhfva5pyvzgatstp 64oj7wsmt5toh46rl3ni2ltz
{
  "authToken": "",
  "authpolicies": [],
  "binaries": [
    {
      "config": {},
      "storeItemBinaryVersion": 3,
      "sysModified": "Wed May 24 20:57:57 UTC 2017",
      "type": "android",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe",
      "versions": [
        {
          "config": {},
          "destinationCode": "android",
          "storeItemBinaryGuid": "3uxxmivxsi7njnbxfikxgefe",
          "storeItemBinaryModified": "Fri Jul 31 13:35:33 UTC 2015",
          "storeItemBinaryVersion": 2,
          "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe&binversGuid=in52m66luesx7bgrjcchsevw&download=true"
        },
        {
          "config": {},
          "destinationCode": "android",
          "storeItemBinaryGuid": "3uxxmivxsi7njnbxfikxgefe",
          "storeItemBinaryModified": "Fri Jul 31 13:35:17 UTC 2015",
          "storeItemBinaryVersion": 1,
          "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe&binversGuid=btmerdcc3invb46s2p4miovk&download=true"
        }
      ]
    },
    {
      "config": {},
      "storeItemBinaryVersion": 1,
      "sysModified": "Mon Aug 24 19:08:12 UTC 2015",
      "type": "ios",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=oe5rdqmzkmwyzvqdjm3aqhqw",
      "versions": []
    },
    {
      "config": {},
      "storeItemBinaryVersion": 1,
      "sysModified": "Tue Sep 27 15:46:47 UTC 2016",
      "type": "iphone",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=tc6fwvqm6rom24msk3of2ctr",
      "versions": []
    }
  ],
  "description": "",
  "groups": [
    "64oj7wsmt5toh46rl3ni2ltz"
  ],
  "guid": "fsresasbhhfva5pyvzgatstp",
  "icon": "",
  "name": "sp-test",
  "restrictToGroups": false,
  "screenshots": [],
  "status": "ok",
  "support": {},
  "version": ""
}
Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems delgroups fsresasbhhfva5pyvzgatstp 64oj7wsmt5toh46rl3ni2ltz
{
  "authToken": "",
  "authpolicies": [],
  "binaries": [
    {
      "config": {},
      "storeItemBinaryVersion": 3,
      "sysModified": "Wed May 24 20:57:57 UTC 2017",
      "type": "android",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe",
      "versions": [
        {
          "config": {},
          "destinationCode": "android",
          "storeItemBinaryGuid": "3uxxmivxsi7njnbxfikxgefe",
          "storeItemBinaryModified": "Fri Jul 31 13:35:33 UTC 2015",
          "storeItemBinaryVersion": 2,
          "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe&binversGuid=in52m66luesx7bgrjcchsevw&download=true"
        },
        {
          "config": {},
          "destinationCode": "android",
          "storeItemBinaryGuid": "3uxxmivxsi7njnbxfikxgefe",
          "storeItemBinaryModified": "Fri Jul 31 13:35:17 UTC 2015",
          "storeItemBinaryVersion": 1,
          "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe&binversGuid=btmerdcc3invb46s2p4miovk&download=true"
        }
      ]
    },
    {
      "config": {},
      "storeItemBinaryVersion": 1,
      "sysModified": "Mon Aug 24 19:08:12 UTC 2015",
      "type": "ios",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=oe5rdqmzkmwyzvqdjm3aqhqw",
      "versions": []
    },
    {
      "config": {},
      "storeItemBinaryVersion": 1,
      "sysModified": "Tue Sep 27 15:46:47 UTC 2016",
      "type": "iphone",
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=tc6fwvqm6rom24msk3of2ctr",
      "versions": []
    }
  ],
  "description": "",
  "groups": [],
  "guid": "fsresasbhhfva5pyvzgatstp",
  "icon": "",
  "name": "sp-test",
  "restrictToGroups": false,
  "screenshots": [],
  "status": "ok",
  "support": {},
  "version": ""
}

To check the binary versions.

Camilas-MacBook-Pro:fh-fhc cmacedo$ ./bin/fhc.js admin appstore storeitems binaryversions --id=fsresasbhhfva5pyvzgatstp
{
  "name": "sp-test",
  "versions": [
    {
      "config": {},
      "destinationCode": "android",
      "storeItemBinaryGuid": "3uxxmivxsi7njnbxfikxgefe",
      "storeItemBinaryModified": "Fri Jul 31 13:35:33 UTC 2015",
      "storeItemBinaryVersion": 2,
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe&binversGuid=in52m66luesx7bgrjcchsevw&download=true"
    },
    {
      "config": {},
      "destinationCode": "android",
      "storeItemBinaryGuid": "3uxxmivxsi7njnbxfikxgefe",
      "storeItemBinaryModified": "Fri Jul 31 13:35:17 UTC 2015",
      "storeItemBinaryVersion": 1,
      "url": "https://support.us.feedhenry.com/box/api/mas/storeitem/install?guid=3uxxmivxsi7njnbxfikxgefe&binversGuid=btmerdcc3invb46s2p4miovk&download=true"
    }
  ]
}

To update group restriction

screen shot 2017-08-13 at 3 47 57 pm