{"id":20185310,"url":"https://github.com/kocyigitkim/realtime.io","last_synced_at":"2025-07-29T05:05:19.024Z","repository":{"id":57348936,"uuid":"330439706","full_name":"kocyigitkim/realtime.io","owner":"kocyigitkim","description":"Real time data streaming \u0026 socket programming library","archived":false,"fork":false,"pushed_at":"2021-11-12T05:32:26.000Z","size":57,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-06-28T08:16:02.353Z","etag":null,"topics":["data","realtime","socket","streaming"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/kocyigitkim.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":"2021-01-17T16:51:23.000Z","updated_at":"2021-11-12T05:32:29.000Z","dependencies_parsed_at":"2022-09-17T23:21:50.079Z","dependency_job_id":null,"html_url":"https://github.com/kocyigitkim/realtime.io","commit_stats":null,"previous_names":["muhammetkocyigit0/realtime.io"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/kocyigitkim/realtime.io","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kocyigitkim%2Frealtime.io","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kocyigitkim%2Frealtime.io/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kocyigitkim%2Frealtime.io/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kocyigitkim%2Frealtime.io/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kocyigitkim","download_url":"https://codeload.github.com/kocyigitkim/realtime.io/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kocyigitkim%2Frealtime.io/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267077053,"owners_count":24032278,"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","status":"online","status_checked_at":"2025-07-25T02:00:09.625Z","response_time":70,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["data","realtime","socket","streaming"],"created_at":"2024-11-14T03:12:46.238Z","updated_at":"2025-07-29T05:05:19.000Z","avatar_url":"https://github.com/kocyigitkim.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n\n# Introduction \nReal time data streaming \u0026 socket programming library\n\n# Getting Started\nSteps:\n1.\tInstallation\n2.\tSoftware dependencies\n3.\tUsage\n\n# 1. Installation\n\n - npm install realtime.io\n - yarn add realtime.io\n \n# 2. Software dependencies\n - socket.io\n - socket.io-client\n - uuid\n - chalk\n - crypto\n - express\n - http\n - node-cache\n # 3. Usage\n\n##### A. _How To Create \u0026 Listen Server_\n```js\n    // Import RealTime.IO Library\n    const realtimeio = require('realtime.io');\n    // Define Server Options\n    // You can inspect server options from library\n    const serverOptions = new realtimeio.server.RealtimeIOServerOptions();\n    // Create RealTime Server\n    const server = new realtimeio.server.RealtimeIOServer(serverOptions);\n    // Listen\n    server.listen();\n```    \n##### B. _How To Define Server Object_\n```js\n    class NotificationServerObject extends realtimeio.server.RealtimeIOServerObject{\n\t    constructor(server){\n\t\t    super('notification', server);\n\t    }\n\t    Listener_showNotification(client, type, title, message){\n\t\t    console.log(['Type: ', type, 'Title: ', title, 'Message: ', message].join(' '));\n\t    }\n    }\n```\n##### C. How To Use Notification Server Object ?\n```js\n    // Listen\n    server.listen();\n    // Write this code after listen server expression\n    const notificationServer = new NotificationServerObject(server);\n```\nThen everything will be nice :)\n\n##### D. How To Create Client ?\n```js\n    // Import RealTime.IO Library\n    const realtimeio = require('realtime.io');\n    // Define Client Options\n    // You can inspect client options from library\n    const clientOptions = new realtimeio.server.RealtimeIOClientOptions();\n    // Create RealTime Client\n    const client = new realtimeio.client.RealtimeIOClient(clientOptions);\n    // Connect to server\n    client.connect();\n```\n##### E. How To Define Client Object?\n```js\n    class NotificationClientObject extends realtimeio.client.RealtimeIOClientObject{\n\t\tconstructor(client){\n\t\t\tsuper('notification', client);\n\t\t}\n\t\tshowNotification(type, title, message){}\n    }\n```\n##### F. How To Send A New Notification ?\n```js\n    // Connect to server\n    client.connect();\n    // Send new notification\n    const notificationObject = new NotificationClientObject(client);\n    notificationObject.showNotification('info', 'Example #1', 'Hello world :)');\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkocyigitkim%2Frealtime.io","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkocyigitkim%2Frealtime.io","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkocyigitkim%2Frealtime.io/lists"}