{"id":1369,"date":"2019-07-15T01:37:58","date_gmt":"2019-07-14T16:37:58","guid":{"rendered":"https:\/\/blog.minatoproject.com\/?p=1369"},"modified":"2020-02-07T23:15:43","modified_gmt":"2020-02-07T14:15:43","slug":"c%e3%81%8b%e3%82%89jupyter-api%e3%81%ab%e3%82%a2%e3%82%af%e3%82%bb%e3%82%b9%e3%81%a7%e3%81%8d%e3%82%8b%e3%83%a9%e3%82%a4%e3%83%96%e3%83%a9%e3%83%aa%e4%bd%9c%e3%81%a3%e3%81%9f","status":"publish","type":"post","link":"https:\/\/blog.minatoproject.com\/?p=1369","title":{"rendered":"C#\u304b\u3089Jupyter API\u306b\u30a2\u30af\u30bb\u30b9\u3067\u304d\u308b\u30e9\u30a4\u30d6\u30e9\u30ea\u4f5c\u3063\u305f"},"content":{"rendered":"<div class=\"veu_autoEyeCatchBox\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/blog.minatoproject.com\/wp-content\/uploads\/2019\/07\/20190715_eyecatch-1024x576.png\" class=\"attachment-large size-large wp-post-image\" alt=\"\" srcset=\"https:\/\/blog.minatoproject.com\/wp-content\/uploads\/2019\/07\/20190715_eyecatch-1024x576.png 1024w, https:\/\/blog.minatoproject.com\/wp-content\/uploads\/2019\/07\/20190715_eyecatch-300x169.png 300w, https:\/\/blog.minatoproject.com\/wp-content\/uploads\/2019\/07\/20190715_eyecatch-768x432.png 768w, https:\/\/blog.minatoproject.com\/wp-content\/uploads\/2019\/07\/20190715_eyecatch-320x180.png 320w, https:\/\/blog.minatoproject.com\/wp-content\/uploads\/2019\/07\/20190715_eyecatch.png 1280w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/div>\n<p>\u307f\u306a\u3068\u3067\u3059\u3002<\/p>\n\n\n\n<p>Jupyter\u306f\u4fbf\u5229\u306a\u306e\u3067\u3059\u304c\u552f\u4e00\u30d5\u30a1\u30a4\u30eb\u8ee2\u9001\u6a5f\u80fd\u306b\u3064\u3044\u3066\u8a00\u3048\u3070\u3053\u308c\u306f\u304a\u307e\u3051\u306e\u304a\u3082\u3061\u3083\u307f\u305f\u3044\u306a\u5b8c\u6210\u5ea6\u3067\u3001\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3054\u3068\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3067\u304d\u306a\u304b\u3063\u305f\u308a\u8907\u6570\u306e\u5927\u5bb9\u91cf\u30d5\u30a1\u30a4\u30eb\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u306b\u96e3\u304c\u3042\u3063\u305f\u308a\u305d\u3082\u305d\u3082\u64cd\u4f5c\u6027\u304c\u7169\u308f\u3057\u304b\u3063\u305f\u308a\u3067UI\u304b\u3089\u304c\u3063\u3064\u308aFTP\u3059\u308b\u67a0\u7d44\u307f\u304c\u672a\u3060\u306b\u6574\u3063\u3066\u3044\u307e\u305b\u3093\u3002<\/p>\n\n\n\n<p>\u307e\u3041\u305d\u3093\u306a\u3082\u306e\u306b\u983c\u3089\u305a\u3068\u3082\u5927\u4f53\u306e\u30b1\u30fc\u30b9\u3067\u306fSFTP\u3067\u30b4\u30ea\u62bc\u3057\u8ee2\u9001\u304c\u3067\u304d\u308b\u74b0\u5883\u306b\u3042\u308b\u304b\u3068\u601d\u3046\u306e\u3067\u305d\u3053\u307e\u3067FTP\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306b\u3053\u3060\u308f\u3089\u306a\u304f\u3066\u3082\u554f\u984c\u306a\u3044\u3068\u3044\u3048\u3070\u306a\u3044\u306e\u3067\u3059\u304c\u3001\u4f55\u3089\u304b\u306e\u653f\u6cbb\u7684\u306a\u7406\u7531\u3067\u958b\u767a\u8005\u304b\u3089\u306eSSH\u63a5\u7d9a\u304c\u8a31\u53ef\u3055\u308c\u3066\u3044\u306a\u3044\u3088\u3046\u306a\u30b1\u30fc\u30b9\u3067\u306f\u6700\u60aa\u300cJupyter\u306b\u30d5\u30a1\u30a4\u30eb\u3092\u8ee2\u9001\u3059\u308b\u305f\u3081\u3060\u3051\u306e\u30c4\u30fc\u30eb\u300d\u3092\u4f5c\u3089\u306a\u3051\u308c\u3070\u306a\u3089\u306a\u3044\u30b1\u30fc\u30b9\u304c\u51fa\u3066\u304d\u307e\u3059\u3002\u3068\u3044\u3046\u304b\u79c1\u306f\u51fa\u3066\u304d\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<p>\u3068\u308a\u3042\u3048\u305aWPF\u8fba\u308a\u3067\u3061\u3083\u3061\u3083\u3063\u3068REST\u6295\u3052\u308bFileZilla\u3063\u307d\u3044UI\u306e\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3092\u4f5c\u308d\u3046\u3068\u601d\u3063\u305f\u306e\u3067\u3059\u304c\u3001\u5272\u3068\u3053\u306e\u6a5f\u80fd\u9700\u8981\u3042\u308a\u305d\u3046\u3060\u306a\u3068\u601d\u3063\u3066\u307e\u305a\u306fdll\u5316\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n\n\n\n<p>\u3067\u3001\u3044\u3044\u611f\u3058\u306b\u3067\u304d\u305f\u306e\u3067\u30d1\u30c3\u30b1\u30fc\u30b8\u30f3\u30b0\u3057\u3066NuGet\u3067\u516c\u958b\u3057\u307e\u3057\u305f\u3002\u4f55\u306e\u3072\u306d\u308a\u3082\u3042\u308a\u307e\u305b\u3093\u304c\u300cJupyterSharp\u300d\u3068\u3044\u3046\u540d\u524d\u3067\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u624b\u9806<\/h2>\n\n\n\n<p>Visual Studio\u3092\u304a\u4f7f\u3044\u306e\u65b9\u306f\u304a\u99b4\u67d3\u307f\u300cNuGet\u30d1\u30c3\u30b1\u30fc\u30b8\u30de\u30cd\u30fc\u30b8\u30e3\u30fc\u300d\u304b\u3089\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u3068\u3088\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u305d\u308c\u4ee5\u5916\u306e\u65b9\u306f\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u304b\u3089\u306b\u306a\u308b\u306e\u3067\u3057\u3087\u3046\u304b\u306d\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism off-numbers lang-plane\"><code>PM&gt; Install-Package JupyterSharp<\/code><\/pre><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">\u4f7f\u3044\u65b9<\/h2>\n\n\n\n<p>GitHub\u3068NuGet\u306eREADME\u306b\u3082\u66f8\u3044\u3066\u3042\u308a\u307e\u3059\u304c\u305b\u3063\u304b\u304f\u306a\u306e\u3067\u65e5\u672c\u8a9e\u3067\u7c21\u5358\u306b\u4f7f\u3044\u65b9\u3092\u8aac\u660e\u3057\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<p>Jupyter\u3078\u306e\u30a2\u30af\u30bb\u30b9\u60c5\u5831\u306f\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3067\u6e21\u3057\u307e\u3059\u3002\u30a2\u30af\u30bb\u30b9\u30c8\u30fc\u30af\u30f3\u3001IP\u30a2\u30c9\u30ec\u30b9\u3001\u30dd\u30fc\u30c8\u756a\u53f7\u306e3\u3064\u3067\u3059\u3002JupyterHub\u306e\u3088\u3046\u306a\u30ed\u30b0\u30a4\u30f3\u8a8d\u8a3c\u3092\u8981\u3059\u308b\u74b0\u5883\u306b\u306f\u73fe\u5728\u5bfe\u5fdc\u3057\u3066\u3044\u307e\u305b\u3093\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism off-numbers lang-csharp\" data-lang=\"C#\"><code>var MyAPI= new JupyterSharp.Api(&quot;ACCESS_TOKEN&quot;, &quot;localhost&quot;, &quot;8888&quot;);<\/code><\/pre><\/div>\n\n\n\n<p>\u305d\u306e\u5f8c\u306eREST\u306e\u5207\u308a\u65b9\u306b\u95a2\u3057\u3066\u306f<a rel=\"noreferrer noopener\" aria-label=\"Jupyter Notebook API (\u65b0\u3057\u3044\u30bf\u30d6\u3067\u958b\u304f)\" href=\"http:\/\/petstore.swagger.io\/?url=https:\/\/raw.githubusercontent.com\/jupyter\/notebook\/master\/notebook\/services\/api\/api.yaml#\/\" target=\"_blank\">Jupyter Notebook API<\/a>\u306b\u307b\u307c\u6e96\u62e0\u3057\u305f\u5f62\u3067\u547c\u3073\u51fa\u305b\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u4f8b\u3048\u3070\u30d5\u30a1\u30a4\u30eb\u3092\u65b0\u898f\u4f5c\u6210\u3057\u3066\u540d\u524d\u3092\u5909\u66f4\u3057\u3066\uff08Jupyter API\u3067\u306f\u4efb\u610f\u306e\u540d\u524d\u4ed8\u304d\u30d5\u30a1\u30a4\u30eb\u3092\u65b0\u898f\u4f5c\u6210\u3067\u304d\u307e\u305b\u3093\uff09\u524a\u9664\u3059\u308b\u3068\u3044\u3046\u4e00\u9023\u306e\u6d41\u308c\u306f\u3053\u3093\u306a\u611f\u3058\u3067\u66f8\u3051\u307e\u3059\u3002\u86c7\u8db3\u3067\u3059\u304cjson\u21d4\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u5909\u63db\u5668\u3082\u4e00\u7dd2\u306b\u4ed8\u3051\u3066\u307e\u3059\uff57<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-csharp\" data-lang=\"C#\"><code>\/\/ \u4e0b\u8a18\u306e\u30a4\u30f3\u30dd\u30fc\u30c8\u304c\u5fc5\u8981\nusing JupyterSharp;\nusing JupyterSharp.Common;\n\n\n\/\/ \u30d5\u30a1\u30a4\u30eb\u751f\u6210\nvar createRequest = MyAPI.CreateContent();\nvar createResponse = JsonConverter.ToObject&lt;Common.Contents&gt;(createRequest.Content);\n\n\/\/ \u30d5\u30a1\u30a4\u30eb\u540d\u5909\u66f4\nvar renameRequest = MyAPI.RenameContent(string.Format(&quot;\/{0}&quot;, createResponse.name), &quot;RenameContentOK&quot;);\nvar renameResponse = JsonConverter.ToObject&lt;Common.Contents&gt;(renameRequest.Content);\n\n\/\/ \u30d5\u30a1\u30a4\u30eb\u524a\u9664\nvar deleteRequest = MyAPI.DeleteContent(string.Format(&quot;\/{0}&quot;, renameResponse.name));<\/code><\/pre><\/div>\n\n\n\n<p>\u3069\u3046\u3067\u3057\u3087\u3046\u3002\u307e\u3060\u51fa\u3057\u305f\u3070\u304b\u308a\u306a\u306e\u3067\u4e0d\u5177\u5408\u30fb\u6539\u5584\u8981\u671b\u306a\u3069\u3042\u308a\u307e\u3057\u305f\u3089\u30c9\u30b7\u30c9\u30b7\u304a\u9858\u3044\u3057\u307e\u3059\u3002<\/p>\n\n\n<div class=\"linkcard\"><div class=\"lkc-external-wrap\"><a class=\"lkc-link no_icon\" href=\"https:\/\/github.com\/step63r\/JupyterSharp\" target=\"_blank\" rel=\"external noopener\"><div class=\"lkc-card\"><div class=\"lkc-info\"><div class=\"lkc-favicon\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.google.com\/s2\/favicons?domain=github.com\" alt=\"\" width=\"16\" height=\"16\" \/><\/div><div class=\"lkc-domain\">GitHub<\/div><\/div><div class=\"lkc-content\"><figure class=\"lkc-thumbnail\"><img decoding=\"async\" class=\"lkc-thumbnail-img\" src=\"\/\/blog.minatoproject.com\/wp-content\/uploads\/pz-linkcard\/cache\/d5c4cbd8f897a8944ceca2e6939e2d3a6b51649effd4f3f5c60a70dd6fe857ed.jpeg\" width=\"100px\" height=\"108px\" alt=\"\" \/><\/figure><div class=\"lkc-title\">step63r\/JupyterSharp<\/div><div class=\"lkc-url\" title=\"https:\/\/github.com\/step63r\/JupyterSharp\">https:\/\/github.com\/step63r\/JupyterSharp<\/div><div class=\"lkc-excerpt\">Access Jupyter API via Visual C#. Contribute to step63r\/JupyterSharp development by creating an account on GitHub.<\/div><\/div><div class=\"clear\"><\/div><\/div><\/a><\/div><\/div>\n\n\n<div class=\"linkcard\"><div class=\"lkc-external-wrap\"><a class=\"lkc-link no_icon\" href=\"https:\/\/www.nuget.org\/packages\/JupyterSharp\/\" target=\"_blank\" rel=\"external noopener\"><div class=\"lkc-card\"><div class=\"lkc-info\"><div class=\"lkc-favicon\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.google.com\/s2\/favicons?domain=www.nuget.org\" alt=\"\" width=\"16\" height=\"16\" \/><\/div><div class=\"lkc-domain\">www.nuget.org<\/div><\/div><div class=\"lkc-content\"><figure class=\"lkc-thumbnail\"><img decoding=\"async\" class=\"lkc-thumbnail-img\" src=\"\/\/blog.minatoproject.com\/wp-content\/uploads\/pz-linkcard\/cache\/eaf7337eebc8369da93ceb9415ebaf6feb002cc232cc3bac0fc1710b5b997583.jpeg\" width=\"100px\" height=\"108px\" alt=\"\" \/><\/figure><div class=\"lkc-title\">JupyterSharp 1.0.0<\/div><div class=\"lkc-url\" title=\"https:\/\/www.nuget.org\/packages\/JupyterSharp\/\">https:\/\/www.nuget.org\/packages\/JupyterSharp\/<\/div><div class=\"lkc-excerpt\">Access Jupyter API via Visual C#.<\/div><\/div><div class=\"clear\"><\/div><\/div><\/a><\/div><\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u307f\u306a\u3068\u3067\u3059\u3002 Jupyter\u306f\u4fbf\u5229\u306a\u306e\u3067\u3059\u304c\u552f\u4e00\u30d5\u30a1\u30a4\u30eb\u8ee2\u9001\u6a5f\u80fd\u306b\u3064\u3044\u3066\u8a00\u3048\u3070\u3053\u308c\u306f\u304a\u307e\u3051\u306e\u304a\u3082\u3061\u3083\u307f\u305f\u3044\u306a\u5b8c\u6210\u5ea6\u3067\u3001\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3054\u3068\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3067\u304d\u306a\u304b\u3063\u305f\u308a\u8907\u6570\u306e\u5927\u5bb9\u91cf\u30d5\u30a1\u30a4\u30eb\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u306b\u96e3\u304c\u3042\u3063\u305f\u308a\u305d\u3082\u305d\u3082\u64cd\u4f5c [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":1575,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"vkexunit_cta_each_option":"","footnotes":""},"categories":[3,6],"tags":[],"class_list":["post-1369","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-c","category-python"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=\/wp\/v2\/posts\/1369","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1369"}],"version-history":[{"count":19,"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=\/wp\/v2\/posts\/1369\/revisions"}],"predecessor-version":[{"id":1803,"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=\/wp\/v2\/posts\/1369\/revisions\/1803"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=\/wp\/v2\/media\/1575"}],"wp:attachment":[{"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1369"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1369"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.minatoproject.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1369"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}