{"id":19885689,"url":"https://github.com/asmod4n/mruby-httpsclient","last_synced_at":"2026-03-05T00:32:56.022Z","repository":{"id":25737630,"uuid":"29175105","full_name":"Asmod4n/mruby-httpsclient","owner":"Asmod4n","description":null,"archived":false,"fork":false,"pushed_at":"2017-04-15T16:25:54.000Z","size":30,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-05-02T16:54:57.350Z","etag":null,"topics":["http-client","mruby"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Asmod4n.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-01-13T05:54:46.000Z","updated_at":"2023-04-11T05:41:52.000Z","dependencies_parsed_at":"2022-08-06T07:01:03.962Z","dependency_job_id":null,"html_url":"https://github.com/Asmod4n/mruby-httpsclient","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Asmod4n/mruby-httpsclient","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Asmod4n%2Fmruby-httpsclient","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Asmod4n%2Fmruby-httpsclient/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Asmod4n%2Fmruby-httpsclient/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Asmod4n%2Fmruby-httpsclient/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Asmod4n","download_url":"https://codeload.github.com/Asmod4n/mruby-httpsclient/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Asmod4n%2Fmruby-httpsclient/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30102397,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-04T23:59:36.199Z","status":"ssl_error","status_checked_at":"2026-03-04T23:56:48.556Z","response_time":59,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["http-client","mruby"],"created_at":"2024-11-12T17:35:18.796Z","updated_at":"2026-03-05T00:32:55.987Z","avatar_url":"https://github.com/Asmod4n.png","language":"Ruby","readme":"﻿# mruby-httpsclient\n\nPrerequirements\n===============\nYou need mruby-tls which needs libressl (http://www.libressl.org) somewhere your compiler can find it, for example on OS X with homebrew you have to add something like this to build_config.rb\n```ruby\n  conf.gem mgem: 'mruby-tls' do |g|\n    g.cc.include_paths \u003c\u003c '/usr/local/opt/libressl/include'\n    g.linker.library_paths \u003c\u003c '/usr/local/opt/libressl/lib'\n  end\n```\n\nExample\n======\n\nSimple GET\n\n```ruby\nHttpsClient.new.get(\"https://github.com/\") do |response|\n  unless response.body\n    puts response.minor_version\n    puts response.status\n    puts response.msg\n    puts response.headers\n  else\n    print response.body\n  end\nend\n```\n\nSimple POST\n\n```ruby\nbody = \"hello world\"\nHttpsClient.new.post(\"https://github.com\", body) do |response|\n  unless response.body\n    puts response.minor_version\n    puts response.status\n    puts response.msg\n    puts response.headers\n  else\n    print response.body\n  end\nend\n```\n\nPOST a Enumerable\n```ruby\nbody = [\"hello\", \"world\"]\nHttpsClient.new.post(\"https://github.com\", body) do |response|\n  unless response.body\n    puts response.minor_version\n    puts response.status\n    puts response.msg\n    puts response.headers\n  else\n    print response.body\n  end\nend\n```\n\nPOST a Fiber\n```ruby\nbody = Fiber.new do\n  Fiber.yield \"hello\"\n  Fiber.yield \"world\"\nend\nHttpsClient.new.post(\"https://github.com\", body) do |response|\n  unless response.body\n    puts response.minor_version\n    puts response.status\n    puts response.msg\n    puts response.headers\n  else\n    print response.body\n  end\nend\n```\n\nThe response body is always streamed, if you need to work with the complete body at once you have to stitch it together.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fasmod4n%2Fmruby-httpsclient","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fasmod4n%2Fmruby-httpsclient","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fasmod4n%2Fmruby-httpsclient/lists"}