{"action":"created","comment":{"url":"https://api.github.com/repos/dwyl/image-uploads/pulls/comments/77993783","id":77993783,"diff_hunk":"@@ -0,0 +1,59 @@\n+## Direct Upload Example\n+\n+We want to upload images to an S3 bucket via an html form.\n+\n+html form -\n+\n+The html form needs to have a meta tag in the head that takes the following to\n+let the browser know that you're using UTF-8 unicode character encoding:\n+\n+```html\n+<meta http-equiv=\"content-type\" content=\"text/html\" charset=\"utf-8\" />\n+```\n+\n+The form needs to send certain information to S3 before the upload can be accepted.\n+If any information is excluded or incorrect the upload will be rejected.\n+\n++ #### Step 1:\n+Assign the action of your form to the bucket URL you want to upload to.\n+If you're new to Amazon Web Services, you'll first have to create an account on the\n+[Amazon Developer Console](aws.amazon.co.uk) Navigate to the S3 console and create\n+your first bucket. To access the bucket URL simply use this format with your\n+bucket name `https://[your-bucket-name].s3.amazonaws.com/`. Alternatively you can\n+include the region explicitly but AWS http://bucket.s3-aws-region.amazonaws.com\n+will be able to find it from the bucket name automatically.\n+\n+```html\n+<body>\n+  <form action=\"https://[your-bucket-name].s3.amazonaws.com/\" method=\"post\" enctype=\"multipart/form-data\">\n+```\n+\n++ #### Step 2:\n+Next you'll want to add the input information that will be sent to AWS in your form.\n+There are 7 that you need to add. They are:\n+\n+```html\n+  /* this is the path to the file you wish to upload */\n+  <input type=\"hidden\" name=\"key\" value=`image-uploads/${filename}`>","path":"examples/direct-upload/README.md","position":37,"original_position":37,"commit_id":"67ea8381cf6295b380fb900cf8d07feff2ecdf0b","original_commit_id":"67ea8381cf6295b380fb900cf8d07feff2ecdf0b","user":{"login":"nelsonic","id":194400,"avatar_url":"https://avatars.githubusercontent.com/u/194400?v=3","gravatar_id":"","url":"https://api.github.com/users/nelsonic","html_url":"https://github.com/nelsonic","followers_url":"https://api.github.com/users/nelsonic/followers","following_url":"https://api.github.com/users/nelsonic/following{/other_user}","gists_url":"https://api.github.com/users/nelsonic/gists{/gist_id}","starred_url":"https://api.github.com/users/nelsonic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nelsonic/subscriptions","organizations_url":"https://api.github.com/users/nelsonic/orgs","repos_url":"https://api.github.com/users/nelsonic/repos","events_url":"https://api.github.com/users/nelsonic/events{/privacy}","received_events_url":"https://api.github.com/users/nelsonic/received_events","type":"User","site_admin":false},"body":"Sadly, we can't use template literals in browser code because of Internet Explorere ... 😠 \r\nhttps://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Template_literals#Browser_compatibility","created_at":"2016-09-08T12:13:44Z","updated_at":"2016-09-08T12:13:44Z","html_url":"https://github.com/dwyl/image-uploads/pull/20#discussion_r77993783","pull_request_url":"https://api.github.com/repos/dwyl/image-uploads/pulls/20","_links":{"self":{"href":"https://api.github.com/repos/dwyl/image-uploads/pulls/comments/77993783"},"html":{"href":"https://github.com/dwyl/image-uploads/pull/20#discussion_r77993783"},"pull_request":{"href":"https://api.github.com/repos/dwyl/image-uploads/pulls/20"}}},"pull_request":{"url":"https://api.github.com/repos/dwyl/image-uploads/pulls/20","id":84338067,"html_url":"https://github.com/dwyl/image-uploads/pull/20","diff_url":"https://github.com/dwyl/image-uploads/pull/20.diff","patch_url":"https://github.com/dwyl/image-uploads/pull/20.patch","issue_url":"https://api.github.com/repos/dwyl/image-uploads/issues/20","number":20,"state":"open","locked":false,"title":"[WiP] Direct upload example","user":{"login":"jackcarlisle","id":12450298,"avatar_url":"https://avatars.githubusercontent.com/u/12450298?v=3","gravatar_id":"","url":"https://api.github.com/users/jackcarlisle","html_url":"https://github.com/jackcarlisle","followers_url":"https://api.github.com/users/jackcarlisle/followers","following_url":"https://api.github.com/users/jackcarlisle/following{/other_user}","gists_url":"https://api.github.com/users/jackcarlisle/gists{/gist_id}","starred_url":"https://api.github.com/users/jackcarlisle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jackcarlisle/subscriptions","organizations_url":"https://api.github.com/users/jackcarlisle/orgs","repos_url":"https://api.github.com/users/jackcarlisle/repos","events_url":"https://api.github.com/users/jackcarlisle/events{/privacy}","received_events_url":"https://api.github.com/users/jackcarlisle/received_events","type":"User","site_admin":false},"body":"### not ready for review\r\n* adds information to the direct-upload example  \r\n#18","created_at":"2016-09-07T17:02:28Z","updated_at":"2016-09-08T12:13:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"62ac41e7b82bb0d73ecd264a238230276084c9f0","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/dwyl/image-uploads/pulls/20/commits","review_comments_url":"https://api.github.com/repos/dwyl/image-uploads/pulls/20/comments","review_comment_url":"https://api.github.com/repos/dwyl/image-uploads/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dwyl/image-uploads/issues/20/comments","statuses_url":"https://api.github.com/repos/dwyl/image-uploads/statuses/67ea8381cf6295b380fb900cf8d07feff2ecdf0b","head":{"label":"dwyl:direct-upload","ref":"direct-upload","sha":"67ea8381cf6295b380fb900cf8d07feff2ecdf0b","user":{"login":"dwyl","id":11708465,"avatar_url":"https://avatars.githubusercontent.com/u/11708465?v=3","gravatar_id":"","url":"https://api.github.com/users/dwyl","html_url":"https://github.com/dwyl","followers_url":"https://api.github.com/users/dwyl/followers","following_url":"https://api.github.com/users/dwyl/following{/other_user}","gists_url":"https://api.github.com/users/dwyl/gists{/gist_id}","starred_url":"https://api.github.com/users/dwyl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dwyl/subscriptions","organizations_url":"https://api.github.com/users/dwyl/orgs","repos_url":"https://api.github.com/users/dwyl/repos","events_url":"https://api.github.com/users/dwyl/events{/privacy}","received_events_url":"https://api.github.com/users/dwyl/received_events","type":"Organization","site_admin":false},"repo":{"id":17365173,"name":"image-uploads","full_name":"dwyl/image-uploads","owner":{"login":"dwyl","id":11708465,"avatar_url":"https://avatars.githubusercontent.com/u/11708465?v=3","gravatar_id":"","url":"https://api.github.com/users/dwyl","html_url":"https://github.com/dwyl","followers_url":"https://api.github.com/users/dwyl/followers","following_url":"https://api.github.com/users/dwyl/following{/other_user}","gists_url":"https://api.github.com/users/dwyl/gists{/gist_id}","starred_url":"https://api.github.com/users/dwyl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dwyl/subscriptions","organizations_url":"https://api.github.com/users/dwyl/orgs","repos_url":"https://api.github.com/users/dwyl/repos","events_url":"https://api.github.com/users/dwyl/events{/privacy}","received_events_url":"https://api.github.com/users/dwyl/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dwyl/image-uploads","description":":sunrise: Effortless Image Uploads","fork":false,"url":"https://api.github.com/repos/dwyl/image-uploads","forks_url":"https://api.github.com/repos/dwyl/image-uploads/forks","keys_url":"https://api.github.com/repos/dwyl/image-uploads/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dwyl/image-uploads/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dwyl/image-uploads/teams","hooks_url":"https://api.github.com/repos/dwyl/image-uploads/hooks","issue_events_url":"https://api.github.com/repos/dwyl/image-uploads/issues/events{/number}","events_url":"https://api.github.com/repos/dwyl/image-uploads/events","assignees_url":"https://api.github.com/repos/dwyl/image-uploads/assignees{/user}","branches_url":"https://api.github.com/repos/dwyl/image-uploads/branches{/branch}","tags_url":"https://api.github.com/repos/dwyl/image-uploads/tags","blobs_url":"https://api.github.com/repos/dwyl/image-uploads/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dwyl/image-uploads/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dwyl/image-uploads/git/refs{/sha}","trees_url":"https://api.github.com/repos/dwyl/image-uploads/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dwyl/image-uploads/statuses/{sha}","languages_url":"https://api.github.com/repos/dwyl/image-uploads/languages","stargazers_url":"https://api.github.com/repos/dwyl/image-uploads/stargazers","contributors_url":"https://api.github.com/repos/dwyl/image-uploads/contributors","subscribers_url":"https://api.github.com/repos/dwyl/image-uploads/subscribers","subscription_url":"https://api.github.com/repos/dwyl/image-uploads/subscription","commits_url":"https://api.github.com/repos/dwyl/image-uploads/commits{/sha}","git_commits_url":"https://api.github.com/repos/dwyl/image-uploads/git/commits{/sha}","comments_url":"https://api.github.com/repos/dwyl/image-uploads/comments{/number}","issue_comment_url":"https://api.github.com/repos/dwyl/image-uploads/issues/comments{/number}","contents_url":"https://api.github.com/repos/dwyl/image-uploads/contents/{+path}","compare_url":"https://api.github.com/repos/dwyl/image-uploads/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dwyl/image-uploads/merges","archive_url":"https://api.github.com/repos/dwyl/image-uploads/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dwyl/image-uploads/downloads","issues_url":"https://api.github.com/repos/dwyl/image-uploads/issues{/number}","pulls_url":"https://api.github.com/repos/dwyl/image-uploads/pulls{/number}","milestones_url":"https://api.github.com/repos/dwyl/image-uploads/milestones{/number}","notifications_url":"https://api.github.com/repos/dwyl/image-uploads/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dwyl/image-uploads/labels{/name}","releases_url":"https://api.github.com/repos/dwyl/image-uploads/releases{/id}","deployments_url":"https://api.github.com/repos/dwyl/image-uploads/deployments","created_at":"2014-03-03T12:20:24Z","updated_at":"2016-09-06T11:20:53Z","pushed_at":"2016-09-08T12:10:28Z","git_url":"git://github.com/dwyl/image-uploads.git","ssh_url":"git@github.com:dwyl/image-uploads.git","clone_url":"https://github.com/dwyl/image-uploads.git","svn_url":"https://github.com/dwyl/image-uploads","homepage":"","size":23700,"stargazers_count":65,"watchers_count":65,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":10,"forks":10,"open_issues":10,"watchers":65,"default_branch":"master"}},"base":{"label":"dwyl:master","ref":"master","sha":"19de66094a16411234795a5ca3ca7d7a8def0287","user":{"login":"dwyl","id":11708465,"avatar_url":"https://avatars.githubusercontent.com/u/11708465?v=3","gravatar_id":"","url":"https://api.github.com/users/dwyl","html_url":"https://github.com/dwyl","followers_url":"https://api.github.com/users/dwyl/followers","following_url":"https://api.github.com/users/dwyl/following{/other_user}","gists_url":"https://api.github.com/users/dwyl/gists{/gist_id}","starred_url":"https://api.github.com/users/dwyl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dwyl/subscriptions","organizations_url":"https://api.github.com/users/dwyl/orgs","repos_url":"https://api.github.com/users/dwyl/repos","events_url":"https://api.github.com/users/dwyl/events{/privacy}","received_events_url":"https://api.github.com/users/dwyl/received_events","type":"Organization","site_admin":false},"repo":{"id":17365173,"name":"image-uploads","full_name":"dwyl/image-uploads","owner":{"login":"dwyl","id":11708465,"avatar_url":"https://avatars.githubusercontent.com/u/11708465?v=3","gravatar_id":"","url":"https://api.github.com/users/dwyl","html_url":"https://github.com/dwyl","followers_url":"https://api.github.com/users/dwyl/followers","following_url":"https://api.github.com/users/dwyl/following{/other_user}","gists_url":"https://api.github.com/users/dwyl/gists{/gist_id}","starred_url":"https://api.github.com/users/dwyl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dwyl/subscriptions","organizations_url":"https://api.github.com/users/dwyl/orgs","repos_url":"https://api.github.com/users/dwyl/repos","events_url":"https://api.github.com/users/dwyl/events{/privacy}","received_events_url":"https://api.github.com/users/dwyl/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dwyl/image-uploads","description":":sunrise: Effortless Image Uploads","fork":false,"url":"https://api.github.com/repos/dwyl/image-uploads","forks_url":"https://api.github.com/repos/dwyl/image-uploads/forks","keys_url":"https://api.github.com/repos/dwyl/image-uploads/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dwyl/image-uploads/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dwyl/image-uploads/teams","hooks_url":"https://api.github.com/repos/dwyl/image-uploads/hooks","issue_events_url":"https://api.github.com/repos/dwyl/image-uploads/issues/events{/number}","events_url":"https://api.github.com/repos/dwyl/image-uploads/events","assignees_url":"https://api.github.com/repos/dwyl/image-uploads/assignees{/user}","branches_url":"https://api.github.com/repos/dwyl/image-uploads/branches{/branch}","tags_url":"https://api.github.com/repos/dwyl/image-uploads/tags","blobs_url":"https://api.github.com/repos/dwyl/image-uploads/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dwyl/image-uploads/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dwyl/image-uploads/git/refs{/sha}","trees_url":"https://api.github.com/repos/dwyl/image-uploads/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dwyl/image-uploads/statuses/{sha}","languages_url":"https://api.github.com/repos/dwyl/image-uploads/languages","stargazers_url":"https://api.github.com/repos/dwyl/image-uploads/stargazers","contributors_url":"https://api.github.com/repos/dwyl/image-uploads/contributors","subscribers_url":"https://api.github.com/repos/dwyl/image-uploads/subscribers","subscription_url":"https://api.github.com/repos/dwyl/image-uploads/subscription","commits_url":"https://api.github.com/repos/dwyl/image-uploads/commits{/sha}","git_commits_url":"https://api.github.com/repos/dwyl/image-uploads/git/commits{/sha}","comments_url":"https://api.github.com/repos/dwyl/image-uploads/comments{/number}","issue_comment_url":"https://api.github.com/repos/dwyl/image-uploads/issues/comments{/number}","contents_url":"https://api.github.com/repos/dwyl/image-uploads/contents/{+path}","compare_url":"https://api.github.com/repos/dwyl/image-uploads/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dwyl/image-uploads/merges","archive_url":"https://api.github.com/repos/dwyl/image-uploads/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dwyl/image-uploads/downloads","issues_url":"https://api.github.com/repos/dwyl/image-uploads/issues{/number}","pulls_url":"https://api.github.com/repos/dwyl/image-uploads/pulls{/number}","milestones_url":"https://api.github.com/repos/dwyl/image-uploads/milestones{/number}","notifications_url":"https://api.github.com/repos/dwyl/image-uploads/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dwyl/image-uploads/labels{/name}","releases_url":"https://api.github.com/repos/dwyl/image-uploads/releases{/id}","deployments_url":"https://api.github.com/repos/dwyl/image-uploads/deployments","created_at":"2014-03-03T12:20:24Z","updated_at":"2016-09-06T11:20:53Z","pushed_at":"2016-09-08T12:10:28Z","git_url":"git://github.com/dwyl/image-uploads.git","ssh_url":"git@github.com:dwyl/image-uploads.git","clone_url":"https://github.com/dwyl/image-uploads.git","svn_url":"https://github.com/dwyl/image-uploads","homepage":"","size":23700,"stargazers_count":65,"watchers_count":65,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":10,"forks":10,"open_issues":10,"watchers":65,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dwyl/image-uploads/pulls/20"},"html":{"href":"https://github.com/dwyl/image-uploads/pull/20"},"issue":{"href":"https://api.github.com/repos/dwyl/image-uploads/issues/20"},"comments":{"href":"https://api.github.com/repos/dwyl/image-uploads/issues/20/comments"},"review_comments":{"href":"https://api.github.com/repos/dwyl/image-uploads/pulls/20/comments"},"review_comment":{"href":"https://api.github.com/repos/dwyl/image-uploads/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dwyl/image-uploads/pulls/20/commits"},"statuses":{"href":"https://api.github.com/repos/dwyl/image-uploads/statuses/67ea8381cf6295b380fb900cf8d07feff2ecdf0b"}}}}
{"actor":{"display_login":"nelsonic"}}