{"id":20802327,"url":"https://github.com/astarte-platform/astarte-device-sdk-elixir","last_synced_at":"2026-03-07T11:04:32.030Z","repository":{"id":42658661,"uuid":"190181492","full_name":"astarte-platform/astarte-device-sdk-elixir","owner":"astarte-platform","description":"Astarte Elixir Device SDK","archived":false,"fork":false,"pushed_at":"2024-04-22T13:38:19.000Z","size":226,"stargazers_count":7,"open_issues_count":8,"forks_count":7,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-11-12T14:11:39.956Z","etag":null,"topics":["elixir","elixir-library","iot-device","iot-framework","mqtt-client"],"latest_commit_sha":null,"homepage":null,"language":"Elixir","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/astarte-platform.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-06-04T10:39:29.000Z","updated_at":"2024-01-25T07:40:29.000Z","dependencies_parsed_at":"2022-09-01T09:20:39.922Z","dependency_job_id":"59fd5b93-f9ec-441c-93a9-8e40f80ae686","html_url":"https://github.com/astarte-platform/astarte-device-sdk-elixir","commit_stats":{"total_commits":115,"total_committers":7,"mean_commits":"16.428571428571427","dds":"0.22608695652173916","last_synced_commit":"074be82576cee2dfd2dc0abed1df4997a06aa7ce"},"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/astarte-platform/astarte-device-sdk-elixir","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astarte-platform%2Fastarte-device-sdk-elixir","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astarte-platform%2Fastarte-device-sdk-elixir/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astarte-platform%2Fastarte-device-sdk-elixir/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astarte-platform%2Fastarte-device-sdk-elixir/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/astarte-platform","download_url":"https://codeload.github.com/astarte-platform/astarte-device-sdk-elixir/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/astarte-platform%2Fastarte-device-sdk-elixir/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30212103,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T09:02:10.694Z","status":"ssl_error","status_checked_at":"2026-03-07T09:02:08.429Z","response_time":53,"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":["elixir","elixir-library","iot-device","iot-framework","mqtt-client"],"created_at":"2024-11-17T18:30:13.318Z","updated_at":"2026-03-07T11:04:27.020Z","avatar_url":"https://github.com/astarte-platform.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!--\nCopyright 2024 SECO Mind Srl\n\nSPDX-License-Identifier: Apache-2.0\n--\u003e\n\n# Astarte Device SDK Elixir\n\nThis project allows you to execute a device communication on your Astarte \ncluster.\n\n## Prerequisites\n\nBefore you begin, ensure you have a running Astarte cluster either on your local machine or accessible remotely. \nTo manually build an Astarte cluster, follow this [guide](https://docs.astarte-platform.org/astarte/latest/010-astarte_in_5_minutes.html). \n\nAlternatively, you can set up an automated instance on Astarte Cloud [here](https://astarte.cloud/).\n\n\n## Supported Versions\n\n| Elixir SDK | Astarte |\n| ---------- | --------|\n| 1.0        | 1.0     |\n| 1.1+       | 1.1+    |\n\n\n## Getting Started\n\nFollow these steps to get started with this project:\n\n1. **Clone the Repository**\n\n   Begin by cloning this repository to your local machine.\n\n```\n\ngit clone https://github.com/astarte-platform/astarte-device-sdk-elixir.git\n```\n\n2. **Install the Elixir and Erlang Version**\n\n   You can use ASDF to install these versions:\n\n```\n\nasdf install\n```\n\n3. **Fetch Dependencies**\n\n   Fetch the project dependencies using the `mix deps.get` command.\n\n```\n\nmix deps.get\n```\n\n4. **Compile the Project**\n\n   Compile the project using the `mix compile` command.\n\n```\n\nmix compile\n```\n\n5. **Run the Project**\n\n   Run the project using the `iex -S mix` command.\n\n```\n\niex -S mix\n```\n\nYou can explore the tools inside by entering the IEx shell and typing \n`h Astarte.Device`.\n\n## Basic Usage\n\nInitialize a device instance\n\nYou can easily initialize a device by following the steps below:\n\n##### Device Options\n\nCreate a device option variable as follows. Use your parameters taken when you \nhave created a device from Astarte Cloud or on astartectl:\n\n```\n\ndevice_options = [ pairing_url: \"https://api.your-astarte-instance/pairing\", realm: \"realm_name\", device_id: \"device_id\", credentials_secret: \"device_secret\" ignore_ssl_errors: false, interface_provider: \"./path-to/interface.json\" ]\n```\n\n##### Interacting with Your Realm\n\nTo interact with your realm, you can either save the Device PID when starting \nthe start_link function or retrieve it later using the get_pid function:\n\n```\n{:ok, pid} = Astarte.Device.start_link(device_options)\n```\n\nor \n```\npid = Astarte.Device.get_pid(\"realm_name\", \"device_id\")\n```\n\nTo send data through your interface, use the set_property or send_datastream \nfunctions. These functions require four parameters: the device process PID, the \ninterface name, the path, and the value you want to send. An optional fifth \nparameter, opts, is also accepted:\n\n\n```\nAstarte.Device.set_property(pid, interface_name, path, value)\nAstarte.Device.send_datastream(pid, interface_name, path, value, opts \\\\ [])\n```\n\n## Contributing\n\nWe welcome contributions! Please read our [contributing guide](#) for details on\n how to submit pull requests to us.\n\n## License\n\nThis project is licensed under the Apache-2.0 License - see the [LICENSE]\n(https://github.com/astarte-platform/astarte-device-sdk-elixir/blob/master/LICENSE) \nfile for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fastarte-platform%2Fastarte-device-sdk-elixir","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fastarte-platform%2Fastarte-device-sdk-elixir","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fastarte-platform%2Fastarte-device-sdk-elixir/lists"}