{"id":13507219,"url":"https://github.com/appcues/exconstructor","last_synced_at":"2026-02-22T14:43:53.375Z","repository":{"id":43706722,"uuid":"49987921","full_name":"appcues/exconstructor","owner":"appcues","description":"An Elixir library for generating struct constructors that handle external data with ease.","archived":false,"fork":false,"pushed_at":"2026-01-23T19:24:33.000Z","size":77,"stargazers_count":292,"open_issues_count":5,"forks_count":20,"subscribers_count":24,"default_branch":"main","last_synced_at":"2026-01-24T09:16:22.812Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/appcues.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2016-01-19T22:34:39.000Z","updated_at":"2026-01-23T19:24:35.000Z","dependencies_parsed_at":"2022-08-28T20:01:11.630Z","dependency_job_id":"3287ab5a-9af5-4829-9e42-229007004725","html_url":"https://github.com/appcues/exconstructor","commit_stats":{"total_commits":60,"total_committers":11,"mean_commits":5.454545454545454,"dds":0.5,"last_synced_commit":"d1f8d3b719fa40f90cd9575dd2409855d9602c4c"},"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/appcues/exconstructor","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/appcues%2Fexconstructor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/appcues%2Fexconstructor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/appcues%2Fexconstructor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/appcues%2Fexconstructor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/appcues","download_url":"https://codeload.github.com/appcues/exconstructor/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/appcues%2Fexconstructor/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29716358,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-22T13:30:57.152Z","status":"ssl_error","status_checked_at":"2026-02-22T13:30:28.561Z","response_time":110,"last_error":"SSL_read: 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":[],"created_at":"2024-08-01T02:00:27.913Z","updated_at":"2026-02-22T14:43:53.367Z","avatar_url":"https://github.com/appcues.png","language":"Elixir","funding_links":[],"categories":["Algorithms and Data structures"],"sub_categories":[],"readme":"# ExConstructor\n\n[![Build Status](https://circleci.com/gh/appcues/exconstructor.svg?style=svg)](https://circleci.com/gh/appcues/exconstructor)\n[![Coverage Status](https://coveralls.io/repos/github/appcues/exconstructor/badge.svg?branch=master)](https://coveralls.io/github/appcues/exconstructor?branch=master)\n[![Hex.pm Version](http://img.shields.io/hexpm/v/exconstructor.svg?style=flat)](https://hex.pm/packages/exconstructor)\n\nExConstructor is an Elixir library that makes it easy to instantiate\nstructs from external data, such as that emitted by a JSON parser.\n\nAdd `use ExConstructor` after a `defstruct` statement to inject\na constructor function into the module.\n\nThe generated constructor, called `new` by default,\nhandles *map-vs-keyword-list*, *string-vs-atom-keys*, and\n*camelCase-vs-under_score* input data issues automatically,\nDRYing up your code and letting you move on to the interesting\nparts of your program.\n\n## Example\n\n```elixir\ndefmodule TestStruct do\n  use ExConstructor\n  defstruct field_one: nil,\n            field_two: nil,\n            field_three: nil,\n            field_four: nil\nend\n\nTestStruct.new(%{\"field_one\" =\u003e \"a\", \"fieldTwo\" =\u003e \"b\", :field_three =\u003e \"c\", :FieldFour =\u003e \"d\"})\n# =\u003e %TestStruct{field_one: \"a\", field_two: \"b\", field_three: \"c\", field_four: \"d\"}\n```\n\n## [Full Documentation](http://hexdocs.pm/exconstructor/ExConstructor.html)\n\n[Full ExConstructor documentation is available on\nHexdocs.pm.](http://hexdocs.pm/exconstructor/ExConstructor.html)\n\n\n## Contributors\n\nMany thanks to those who've contributed to ExConstructor:\n\n* Graeme Coupar ([@grambo](https://github.com/grambo))\n* Mel Kicchi ([@meowy](https://github.com/meowy))\n* Andrey Ronin ([@anronin](https://github.com/anronin))\n* Eugene ([@txssu](https://github.com/txssu))\n\n\n## How to Contribute\n\nMy favorite contributions are PRs with code that matches project style,\nand that come with full test coverage and documentation.  I have a hard\ntime saying no to them.\n\nFeature requests are also welcome, but the timeline may be much longer.\n\nBug reports are great -- please include as much information as possible\n(Erlang/Elixir/Mix version, dependencies and their versions, minimal\ntest case, etc.) and I will be much quicker in resolving the issue.\n\n\n## Authorship and License\n\nExConstructor is copyright 2016-2025 Appcues, Inc.\n\nExConstructor is released under the\n[MIT License](https://github.com/appcues/exconstructor/blob/master/LICENSE.txt).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fappcues%2Fexconstructor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fappcues%2Fexconstructor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fappcues%2Fexconstructor/lists"}