{"id":25081781,"url":"https://github.com/rapideinternet/afd.connectors","last_synced_at":"2025-06-14T06:03:18.819Z","repository":{"id":33275797,"uuid":"155851739","full_name":"rapideinternet/afd.connectors","owner":"rapideinternet","description":"A package containing connectors to fetch AFD messages","archived":false,"fork":false,"pushed_at":"2023-12-15T02:24:41.000Z","size":57,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-06-05T23:47:17.646Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rapideinternet.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2018-11-02T10:38:10.000Z","updated_at":"2022-04-06T17:01:26.000Z","dependencies_parsed_at":"2025-02-07T05:19:43.157Z","dependency_job_id":"9fb1b4c2-729b-4bd3-bcc2-7f31a9793281","html_url":"https://github.com/rapideinternet/afd.connectors","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/rapideinternet/afd.connectors","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapideinternet%2Fafd.connectors","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapideinternet%2Fafd.connectors/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapideinternet%2Fafd.connectors/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapideinternet%2Fafd.connectors/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rapideinternet","download_url":"https://codeload.github.com/rapideinternet/afd.connectors/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rapideinternet%2Fafd.connectors/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259768511,"owners_count":22908228,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":"2025-02-07T05:18:55.394Z","updated_at":"2025-06-14T06:03:18.800Z","avatar_url":"https://github.com/rapideinternet.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SIVI AFD Connectors\nCurrently implemented:\n- TIMEConnector\n\n## TIMEConnector\nThe TIMEConnector implements the [TIME API](https://solera.nl/time). A prerequisite \nfor using this API is that you have a valid [Solera Digital Passport](https://solera.nl/bedrijfscertificaat/).\n\n### How to \nInstantiation requires a `TIMEConfig` interface which you will need to implement \nto provide the connector with configuration details.\n\nExample implementation:\n\n```php\nclass TIMEConfig implements \\SIVI\\AFDConnectors\\Config\\Contracts\\TIMEConfig\n{\n    \n    protected $host;\n    protected $wsdlStoragePath;\n    protected $certificatePath;\n    protected $certificatePassphrase;\n\n    public function __construct($host, $wsdlStoragePath, $certificatePath, $certificatePassphrase)\n    {\n        $this-\u003ehost = $host;\n        $this-\u003ewsdlStoragePath = $wsdlStoragePath;\n        $this-\u003ecertificatePath = $certificatePath;\n        $this-\u003ecertificatePassphrase = $certificatePassphrase;\n    }\n\n    /**\n     * Get the host of the service\n     *\n     * @return string\n     */\n    public function getHost()\n    {\n        return $this-\u003ehost;\n    }\n\n    /**\n     * The path where the WSDL for the service will be stored.\n     *\n     * This is because the WSDL is not public and needs to be requested with\n     * a client certificate. The PHP SOAP extension does not support\n     * this and that is why a local one must be created.\n     *\n     * @return string\n     */\n    public function getWSDLStoragePath()\n    {\n        return $this-\u003ewsdlStoragePath;\n    }\n\n    /**\n     * The path where the Solera certificate is stored.\n     * This needs to be a PEM file.\n     *\n     * @return string\n     */\n    public function getCertificatePath()\n    {\n        return $this-\u003ecertificatePath;\n    }\n\n    /**\n     * The passphrase of the Solera certificate.\n     *\n     * @return string\n     */\n    public function getCertificatePassphrase()\n    {\n        return $this-\u003ecertificatePassphrase;\n    }\n}\n```\n\nAfter you've got your config sorted it's time to get some messages. This piece of \ncode will get all unread messages from TIME and print them.\n\n\n```php\nuse SIVI\\AFDConnectors\\Connectors\\TIMEConnector;\n\n// Initialize config\n$config = new TIMEConfig(\n    'https://www.web.service/sts/portal',\n    '/tmp/',\n    '/path/to/solera/certificate.pem',\n    'certificate password'\n);\n\n// Initialize connector\n$connector = new TIMEConnector($config);\n\n// This will return an array of SIVI\\AFD\\Interfaces\\TIME\\Message items \n// which implement the SIVI\\AFD\\Interfaces\\BatchMessage interface. \nforeach ($connector-\u003egetMessage() as $batchMessage) {\n    // This will return an array of SIVI\\AFD\\Interfaces\\TIME\\Message items \n    // which implement the SIVI\\AFD\\Interfaces\\Message interface.\n    foreach ($batchMessage-\u003egetMessages() as $message) {\n        echo sprintf('TIME Message extension: %s%s', $message-\u003egetType(), PHP_EOL);\n        echo sprintf('TIME Message content: %s%s%s', PHP_EOL, $message-\u003egetData(), PHP_EOL);\n    }\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frapideinternet%2Fafd.connectors","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frapideinternet%2Fafd.connectors","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frapideinternet%2Fafd.connectors/lists"}