astroinsightapi-sdk 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +21 -0
  3. data/README.md +153 -0
  4. data/lib/astroinsight/client.rb +46 -0
  5. data/lib/astroinsight/configuration.rb +28 -0
  6. data/lib/astroinsight/error.rb +28 -0
  7. data/lib/astroinsight/http_client.rb +82 -0
  8. data/lib/astroinsight/models/birth_details.rb +39 -0
  9. data/lib/astroinsight/models/geo_location.rb +27 -0
  10. data/lib/astroinsight/models/match_input.rb +46 -0
  11. data/lib/astroinsight/services/chinese_astrology.rb +35 -0
  12. data/lib/astroinsight/services/geo.rb +23 -0
  13. data/lib/astroinsight/services/horoscope.rb +37 -0
  14. data/lib/astroinsight/services/tarot.rb +51 -0
  15. data/lib/astroinsight/services/vedic/ashtakvarga.rb +25 -0
  16. data/lib/astroinsight/services/vedic/astro_details.rb +48 -0
  17. data/lib/astroinsight/services/vedic/biorhythm.rb +18 -0
  18. data/lib/astroinsight/services/vedic/char_dasha.rb +30 -0
  19. data/lib/astroinsight/services/vedic/horoscope_chart.rb +25 -0
  20. data/lib/astroinsight/services/vedic/horoscope_dosha.rb +33 -0
  21. data/lib/astroinsight/services/vedic/jaimini.rb +23 -0
  22. data/lib/astroinsight/services/vedic/kp.rb +28 -0
  23. data/lib/astroinsight/services/vedic/lal_kitab.rb +35 -0
  24. data/lib/astroinsight/services/vedic/life_report.rb +18 -0
  25. data/lib/astroinsight/services/vedic/match_making.rb +28 -0
  26. data/lib/astroinsight/services/vedic/muhurta.rb +35 -0
  27. data/lib/astroinsight/services/vedic/numerology.rb +18 -0
  28. data/lib/astroinsight/services/vedic/panchang.rb +28 -0
  29. data/lib/astroinsight/services/vedic/suggestions.rb +28 -0
  30. data/lib/astroinsight/services/vedic/varshaphal.rb +38 -0
  31. data/lib/astroinsight/services/vedic/vimshottari_dasha.rb +40 -0
  32. data/lib/astroinsight/services/vedic/yogini_dasha.rb +28 -0
  33. data/lib/astroinsight/services/vedic_container.rb +52 -0
  34. data/lib/astroinsight/services/western/natal_astrology.rb +33 -0
  35. data/lib/astroinsight/services/western/solar_return.rb +33 -0
  36. data/lib/astroinsight/services/western/transit.rb +43 -0
  37. data/lib/astroinsight/services/western/transit_chart.rb +23 -0
  38. data/lib/astroinsight/services/western/western_numerology.rb +38 -0
  39. data/lib/astroinsight/services/western/zodiac.rb +23 -0
  40. data/lib/astroinsight/services/western_container.rb +25 -0
  41. data/lib/astroinsight/version.rb +5 -0
  42. data/lib/astroinsight.rb +18 -0
  43. data/lib/astroinsightapi-sdk.rb +3 -0
  44. metadata +89 -0
@@ -0,0 +1,43 @@
1
+ # frozen_string_literal: true
2
+
3
+ module AstroInsight
4
+ module Services
5
+ module Western
6
+ class TransitService
7
+ def initialize(client)
8
+ @client = client
9
+ end
10
+
11
+ def get_daily_natal_transit(birth_details)
12
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
13
+ @client.post("/western/transits/natal/daily", payload)
14
+ end
15
+
16
+ def get_weekly_natal_transit(birth_details)
17
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
18
+ @client.post("/western/transits/natal/weekly", payload)
19
+ end
20
+
21
+ def get_monthly_natal_transit(birth_details)
22
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
23
+ @client.post("/western/transits/natal/monthly", payload)
24
+ end
25
+
26
+ def get_daily_timing(birth_details)
27
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
28
+ @client.post("/western/transits/natal/timing/daily", payload)
29
+ end
30
+
31
+ def get_weekly_timing(birth_details)
32
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
33
+ @client.post("/western/transits/natal/timing/weekly", payload)
34
+ end
35
+
36
+ def get_monthly_timing(birth_details)
37
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
38
+ @client.post("/western/transits/natal/timing/monthly", payload)
39
+ end
40
+ end
41
+ end
42
+ end
43
+ end
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module AstroInsight
4
+ module Services
5
+ module Western
6
+ class TransitChartService
7
+ def initialize(client)
8
+ @client = client
9
+ end
10
+
11
+ def get_wheel_chart(birth_details)
12
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
13
+ @client.post("/western/transits/natal/wheel-chart", payload)
14
+ end
15
+
16
+ def get_aspects_grid(birth_details)
17
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
18
+ @client.post("/western/transits/natal/aspects-grid", payload)
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,38 @@
1
+ # frozen_string_literal: true
2
+
3
+ module AstroInsight
4
+ module Services
5
+ module Western
6
+ class WesternNumerologyService
7
+ def initialize(client)
8
+ @client = client
9
+ end
10
+
11
+ def get_numerological_numbers(birth_details)
12
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
13
+ @client.post("/western/numerology/numerological-numbers", payload)
14
+ end
15
+
16
+ def get_life_path_report(birth_details)
17
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
18
+ @client.post("/western/numerology/report/life-path-number", payload)
19
+ end
20
+
21
+ def get_expression_report(birth_details)
22
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
23
+ @client.post("/western/numerology/report/expression-number", payload)
24
+ end
25
+
26
+ def get_soul_urge_report(birth_details)
27
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
28
+ @client.post("/western/numerology/report/soul-urge-number", payload)
29
+ end
30
+
31
+ def get_personality_report(birth_details)
32
+ payload = birth_details.respond_to?(:to_h) ? birth_details.to_h : birth_details
33
+ @client.post("/western/numerology/report/personality-number", payload)
34
+ end
35
+ end
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "cgi"
4
+
5
+ module AstroInsight
6
+ module Services
7
+ module Western
8
+ class ZodiacService
9
+ def initialize(client)
10
+ @client = client
11
+ end
12
+
13
+ def get_compatibility(sign_key, payload = {})
14
+ @client.post("/western/zodiac/compatibility/#{CGI.escape(sign_key)}", payload)
15
+ end
16
+
17
+ def get_compatibility_report(your_sign_key, partner_sign_key, payload = {})
18
+ @client.post("/western/zodiac/compatibility/#{CGI.escape(your_sign_key)}/#{CGI.escape(partner_sign_key)}", payload)
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,25 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative "western/natal_astrology"
4
+ require_relative "western/solar_return"
5
+ require_relative "western/transit"
6
+ require_relative "western/transit_chart"
7
+ require_relative "western/western_numerology"
8
+ require_relative "western/zodiac"
9
+
10
+ module AstroInsight
11
+ module Services
12
+ class WesternContainer
13
+ attr_reader :natal, :solar_return, :transit, :transit_chart, :numerology, :zodiac
14
+
15
+ def initialize(client)
16
+ @natal = Western::NatalAstrologyService.new(client)
17
+ @solar_return = Western::SolarReturnService.new(client)
18
+ @transit = Western::TransitService.new(client)
19
+ @transit_chart = Western::TransitChartService.new(client)
20
+ @numerology = Western::WesternNumerologyService.new(client)
21
+ @zodiac = Western::ZodiacService.new(client)
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,5 @@
1
+ # frozen_string_literal: true
2
+
3
+ module AstroInsight
4
+ VERSION = "1.0.0"
5
+ end
@@ -0,0 +1,18 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative "astroinsight/version"
4
+ require_relative "astroinsight/error"
5
+ require_relative "astroinsight/configuration"
6
+ require_relative "astroinsight/http_client"
7
+ require_relative "astroinsight/models/birth_details"
8
+ require_relative "astroinsight/models/match_input"
9
+ require_relative "astroinsight/models/geo_location"
10
+ require_relative "astroinsight/client"
11
+
12
+ module AstroInsight
13
+ class << self
14
+ def new(client_id: nil, client_secret: nil, **options)
15
+ Client.new(client_id: client_id, client_secret: client_secret, **options)
16
+ end
17
+ end
18
+ end
@@ -0,0 +1,3 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative "astroinsight"
metadata ADDED
@@ -0,0 +1,89 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: astroinsightapi-sdk
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Astro Insight Team
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2026-08-16 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: Pure Ruby client library for Astro Insight API providing Vedic Astrology,
14
+ Western Astrology, Panchang, Tarot, Numerology, and Geolocation services.
15
+ email:
16
+ - support@astroinsightapi.com
17
+ executables: []
18
+ extensions: []
19
+ extra_rdoc_files: []
20
+ files:
21
+ - LICENSE.txt
22
+ - README.md
23
+ - lib/astroinsight.rb
24
+ - lib/astroinsight/client.rb
25
+ - lib/astroinsight/configuration.rb
26
+ - lib/astroinsight/error.rb
27
+ - lib/astroinsight/http_client.rb
28
+ - lib/astroinsight/models/birth_details.rb
29
+ - lib/astroinsight/models/geo_location.rb
30
+ - lib/astroinsight/models/match_input.rb
31
+ - lib/astroinsight/services/chinese_astrology.rb
32
+ - lib/astroinsight/services/geo.rb
33
+ - lib/astroinsight/services/horoscope.rb
34
+ - lib/astroinsight/services/tarot.rb
35
+ - lib/astroinsight/services/vedic/ashtakvarga.rb
36
+ - lib/astroinsight/services/vedic/astro_details.rb
37
+ - lib/astroinsight/services/vedic/biorhythm.rb
38
+ - lib/astroinsight/services/vedic/char_dasha.rb
39
+ - lib/astroinsight/services/vedic/horoscope_chart.rb
40
+ - lib/astroinsight/services/vedic/horoscope_dosha.rb
41
+ - lib/astroinsight/services/vedic/jaimini.rb
42
+ - lib/astroinsight/services/vedic/kp.rb
43
+ - lib/astroinsight/services/vedic/lal_kitab.rb
44
+ - lib/astroinsight/services/vedic/life_report.rb
45
+ - lib/astroinsight/services/vedic/match_making.rb
46
+ - lib/astroinsight/services/vedic/muhurta.rb
47
+ - lib/astroinsight/services/vedic/numerology.rb
48
+ - lib/astroinsight/services/vedic/panchang.rb
49
+ - lib/astroinsight/services/vedic/suggestions.rb
50
+ - lib/astroinsight/services/vedic/varshaphal.rb
51
+ - lib/astroinsight/services/vedic/vimshottari_dasha.rb
52
+ - lib/astroinsight/services/vedic/yogini_dasha.rb
53
+ - lib/astroinsight/services/vedic_container.rb
54
+ - lib/astroinsight/services/western/natal_astrology.rb
55
+ - lib/astroinsight/services/western/solar_return.rb
56
+ - lib/astroinsight/services/western/transit.rb
57
+ - lib/astroinsight/services/western/transit_chart.rb
58
+ - lib/astroinsight/services/western/western_numerology.rb
59
+ - lib/astroinsight/services/western/zodiac.rb
60
+ - lib/astroinsight/services/western_container.rb
61
+ - lib/astroinsight/version.rb
62
+ - lib/astroinsightapi-sdk.rb
63
+ homepage: https://github.com/AstroInsightApi/astroinsight-ruby-sdk
64
+ licenses:
65
+ - MIT
66
+ metadata:
67
+ homepage_uri: https://github.com/AstroInsightApi/astroinsight-ruby-sdk
68
+ source_code_uri: https://github.com/AstroInsightApi/astroinsight-ruby-sdk.git
69
+ bug_tracker_uri: https://github.com/AstroInsightApi/astroinsight-ruby-sdk/issues
70
+ post_install_message:
71
+ rdoc_options: []
72
+ require_paths:
73
+ - lib
74
+ required_ruby_version: !ruby/object:Gem::Requirement
75
+ requirements:
76
+ - - ">="
77
+ - !ruby/object:Gem::Version
78
+ version: 2.7.0
79
+ required_rubygems_version: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - ">="
82
+ - !ruby/object:Gem::Version
83
+ version: '0'
84
+ requirements: []
85
+ rubygems_version: 3.0.3.1
86
+ signing_key:
87
+ specification_version: 4
88
+ summary: Official Ruby SDK for Astro Insight API.
89
+ test_files: []