UnixstickersのWeb terminalで購入

### アカウント作成
https://www.unixstickers.com/index.php?route=account/register

facebook接続でも作成可能だが結局パスワードと住所が必要となるため
following formで作成したほうがよい。


### ターミナルでカートに商品追加
以下のURLにアクセスしターミナル入力
https://www.unixstickers.com/terminal



### コマンド一覧確認
```
[hoge:unixstickers ~]$ 
cart    catalog    ls    checkout    whoami    logout    account    pwd    help
```






### help表示



```
[hoge:unixstickers ~]$ help 
YYY                                                                                            
              YYYYY                                                                                            
            YYYYYYY                      ###                       #        ##                                 
          VYYYYYYYY                      W##W                     W##       WW                                 
        XYYYYYYYYYt                      :BR                  #B  .I        WW                                 
       RYYYYYYYYYYV    ###  ### #######  ### ###  ####  ###   #R#  #    ### WW   ##  ###   #  ##  ##           
       WiYYYYYYYI;#    ##W  ##W X####### B## i### ##W #####WW####XX## ##### WW  ##, #####  #W##I#####M         
       W#tYYYYYI #W    ##W  ##W X##Mt### B##  X#####= #W   :  #R  V####R    WW ##: ##  Y## ##:  #R   ,         
       W#R;YYYI ##W    ##W  ##W X##  R## B##   ####I  M##     #R  V##W#t    WW##   #R   #M #R   W##            
       W#R  .   ##W    ##W  ##W X##  R## B##   ,##M   ,W###   #R  V##W#     WW#M   ######M #B   :####          
       W#R      ##W    ##W  ##W X##  R## B##   ####     +W##  #R  V##M#     W#I##  #I====; #B     i###         
       W#R      ##W    ### ###W X##  R## B##  ###M##      M#  #R  V##B##    WW B## #W      #B       #W         
       W#R      ##W    R######W X##  R## B##  ##B,### ## ##W  ## #V##.##### WW ,## R#####  #B   ## ##R         
       B#M      M#M     W###i#W X##  R## B## ###; V###W####   M##RX## :#### #W  ;## R####  #B   ####W          
       V##      ##I      ..   .  .    ..  .. ...   .., ...     ..  .    ... .    ..  ...         ...           
        ###    ###+                                                                                            
         ########,                                                                                             
          iBWWMt                                                                                 
                                                                                                 
                                                                                                                   
                                                                       
Available commands:
catalog [--help]          show categories and products.
cart [--help]             show cart content, add/remove products and more.
account [--help]          login/logout, show account info and orders.
checkout                  go to checkout.
``` 



### ログイン

```
$ account login [-u email] [-p password]
[guest:unixstickers ~]$ account login -u hoge@example.jp -p password
Hello hoge, welcome back!
```

### アカウント確認

```
[hoge:unixstickers ~]$ whoami 
hoge yamada
``` 





### 商品 キーワード検索

```
[hoge:unixstickers ~]$ catalog search "linux inside"
 
Found something cool:
+----------------------------------------------------------+------------+--------+------------------------------+
|                           NAME                           | PRODUCT ID | PRICE  |         ADD TO CART          |
+----------------------------------------------------------+------------+--------+------------------------------+
| Kit of 3 linux inside circle keyboard stickers           | 227        | $2.69  | # cart add 227 [-q quantity] |
| Kit of 3 linux inside square keyboard stickers           | 226        | $2.69  | # cart add 226 [-q quantity] |
| Linux Inside badge sticker                               | 322        | $0.69  | # cart add 322 [-q quantity] |
| Linux Inside Black Coffee Mug (2 Free stickers included) | 361        | $14.99 | # cart add 361 [-q quantity] |
| Linux Inside black pin / button                          | 243        | $2.49  | # cart add 243 [-q quantity] |
| Linux inside logo shaped sticker                         | 190        | $2.69  | # cart add 190 [-q quantity] |
| The Linux Inside Kit                                     | 408        | $8.56  | # cart add 408 [-q quantity] |
+----------------------------------------------------------+------------+--------+------------------------------+

```


 
 


### 商品 詳細確認 

```
[hoge:unixstickers ~]$ catalog product 408
+----------------------+------------+------------------+------------------------------+
|         NAME         | PRODUCT ID |      PRICE       |         ADD TO CART          |
+----------------------+------------+------------------+------------------------------+
| The Linux Inside Kit | 408        | [$8.56] -> $6.99 | # cart add 408 [-q quantity] |
+----------------------+------------+------------------+------------------------------+
 
URL
http://www.unixstickers.com/linux-pins-buttons/linux-distributions-pins-buttons/linux-inside-kit-stickers-and-pins
 
Description
 
    The Linux Inside Kit, 5 stickers and 1 pin.
 
    If bought individually: $8.56
    Special price: $6.99
 
    This bundle include 5 stickers
 
    - Linux Inside badge
    - Linux Inside shaped
    - A kit of 3 Linux Inside keyboard sticker
 
    and 1 pin
 
    - Linux Inside pin
 
    The Sticker can be removed without tearing. Our stickers do not leave residues on surfaces.
    UnixStickers.com is not affiliated with any project its stickers refer to. All trademarks are property of their
 respective owners.
 
....
...
..
 

```




URLのリンクをクリックすれば別タブで画像が確認できる。
値下げ前情報がしっかりPRICEに反映されているところがにくい。


### 商品追加

```

[hoge:unixstickers ~]$ cart add 408
 
The Linux Inside Kit has been added to your cart.
 
Your cart:
+----------------------+------------+----------+-------+-------+
|         NAME         | PRODUCT ID | QUANTITY | PRICE | TOTAL |
+----------------------+------------+----------+-------+-------+
| The Linux Inside Kit | 408        | 1        | $6.99 | $6.99 |
|                      |            |          |       |       |
| Sub-Total            |            |          |       | $6.99 |
| Total                |            |          |       | $6.99 |
+----------------------+------------+----------+-------+-------+

```





### 船便コスト確認

```

[hoge:unixstickers ~]$ cart shipping  -country 107 -zone 1697  -postcode 9998888
 
Shipping options:
+------------------------+--------+
|          TYPE          |  COST  |
+------------------------+--------+
| Trackable shipment     | $11.00 |
| Non trackable shipment | $6.00  |
+------------------------+--------+

```

contryに国ID zoneに都道府県ID postcode に郵便番号を指定。国IDと都道府県IDは以下のコマンドで確認可能。


国ID確認

```

[hoge:unixstickers ~]$ cart shipping 
+--------------------------------------------+------------+
|                    NAME                    | COUNTRY ID |
+--------------------------------------------+------------+
| Afghanistan                                | 1          |
'~~~~
| Jamaica                                    | 106        |
| Japan                                      | 107        |
| Jordan                                     | 108        |
'~~~~
| Zimbabwe                                   | 239        |
+--------------------------------------------+------------+
 Add option -country country_id
Example: cart shipping -country

```


日本の Zone ID確認

```

[hoge:unixstickers ~]$ cart shipping  -country 107 

+-----------+---------+
|   NAME    | ZONE ID |
+-----------+---------+
| Aichi     | 1657    |
'~~~~
| Tokyo     | 1697    |
'~~~~
| Yamanashi | 1703    |
+-----------+---------+
 Add option -zone zone_id
Example: cart shipping -country 223 -zone 6152
 
```

### 購入

```

[hoge:unixstickers ~]$ checkout 

```

コンソールからCheckout画面へ遷移する。
後は通常通りに購入手続きを行う。
事前にHome >> Account >> Address Bookから住所を登録しておかないと住所登録画面となる。
※どうでもいいけどクレジットカードはJCBが使えないのでJCBしかない人はPayPalで支払いをしよう。