Skip to content

Commit

Permalink
feat: Siri
Browse files Browse the repository at this point in the history
Update response.dev.js
Update request.dev.js
Update response.js
Update request.js
  • Loading branch information
VirgilClyne committed Dec 10, 2024
1 parent 86e4333 commit c2df0fb
Show file tree
Hide file tree
Showing 17 changed files with 127 additions and 105 deletions.
10 changes: 5 additions & 5 deletions modules/iRingo.Search.plugin
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ LogLevel = select,"WARN","OFF","ERROR","INFO","DEBUG","ALL",tag=[调试] 日志

[Script]
# Bag (iOS/macOS)
http-request ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, tag=⭕ Siri.Bag.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js, requires-body=1, tag=⭕ Siri.Bag.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-request ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, tag=⭕ Siri.Bag.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag script-path=https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js, requires-body=1, tag=⭕ Siri.Bag.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
# Siri Suggestions & Look Up Search (iOS/macOS)
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/search script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, tag=🔍 Siri.Search.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/search script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js, requires-body=1, tag=🔍 Siri.Search.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/search script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, tag=🔍 Siri.Search.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/search script-path=https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js, requires-body=1, tag=🔍 Siri.Search.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
# Flight Search (iOS/macOS)
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/flight script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, tag=🛫 Siri.Flight.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/flight script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, tag=🛫 Siri.Flight.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]

[MITM]
hostname = api*.smoot.apple.com, api.smoot.apple.cn
10 changes: 5 additions & 5 deletions modules/iRingo.Search.sgmodule
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@

[Script]
# Bag (iOS/macOS)
⭕ Siri.Bag.request = type=http-request, pattern=^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag, requires-body=0, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
⭕ Siri.Bag.response = type=http-response, pattern=^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag, requires-body=1, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
⭕ Siri.Bag.request = type=http-request, pattern=^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag, requires-body=0, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
⭕ Siri.Bag.response = type=http-response, pattern=^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag, requires-body=1, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
# Siri Suggestions & Look Up Search (iOS/macOS)
🔍 Siri.Search.request = type=http-request, pattern=^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search, requires-body=0, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
🔍 Siri.Search.response = type=http-response, pattern=^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search, requires-body=1, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
🔍 Siri.Search.request = type=http-request, pattern=^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search, requires-body=0, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
🔍 Siri.Search.response = type=http-response, pattern=^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search, requires-body=1, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
# Flight Search (iOS/macOS)
🛫 Siri.Flight.request = type=http-request, pattern=^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/flight, requires-body=0, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
🛫 Siri.Flight.request = type=http-request, pattern=^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/flight, requires-body=0, engine=webview, script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, argument=CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"

[MITM]
hostname = %APPEND% api*.smoot.apple.com, api.smoot.apple.cn
14 changes: 7 additions & 7 deletions modules/iRingo.Search.snippet
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@

#[rewrite_local]
# ⭕ Siri Bag (iOS/macOS)
^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag url script-request-header https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js
^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag url script-response-body https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js
^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag url script-request-header https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js
^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag url script-response-body https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js
# 🔍 Siri Suggestions & Look Up Search (iOS/macOS)
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search url script-request-header https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search url script-response-body https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search url script-request-header https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search url script-response-body https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js
# 📇 Siri Infomation Card (macOS)
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/card url script-request-header https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/card url script-response-body https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/card url script-request-header https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/card url script-response-body https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js
# 🛫 Siri Flight Search (iOS/macOS)
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/flight url script-request-header https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js
^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/flight url script-request-header https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js

#[mitm]
hostname = api*.smoot.apple.com, api.smoot.apple.cn
4 changes: 2 additions & 2 deletions modules/iRingo.Search.stoverride
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ http:

script-providers:
Siri.request:
url: https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js
url: https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js
interval: 86400
Siri.response:
url: https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js
url: https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js
interval: 86400
10 changes: 5 additions & 5 deletions modules/iRingo.Search.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,35 +15,35 @@ scriptings:
- http_request:
name: ⭕ Siri.Bag.request
match: ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag
script_url: https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js
script_url: https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js
arguments:
_compat.$argument: CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
body_required: false
- http_response:
name: ⭕ Siri.Bag.response
match: ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag
script_url: https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js
script_url: https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js
arguments:
_compat.$argument: CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
body_required: true
- http_request:
name: 🔍 Siri.Search.request
match: ^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search
script_url: https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js
script_url: https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js
arguments:
_compat.$argument: CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
body_required: false
- http_response:
name: 🔍 Siri.Search.response
match: ^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/search
script_url: https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js
script_url: https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js
arguments:
_compat.$argument: CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
body_required: true
- http_request:
name: 🛫 Siri.Flight.request
match: ^https?:\/\/api(2|-.+)\.smoot\.apple\.com\/flight
script_url: https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js
script_url: https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js
arguments:
_compat.$argument: CountryCode="{{{CountryCode}}}"&Domains="{{{Domains}}}"&Functions="{{{Functions}}}"&SafariSmartHistory="{{{SafariSmartHistory}}}"&LogLevel="{{{LogLevel}}}"
body_required: false
Expand Down
14 changes: 7 additions & 7 deletions modules/iRingo.Spotlight.plugin
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,16 @@ DOMAIN,e16991.b.akamaiedge.net

[Script]
# Bag (iOS/macOS)
http-request ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, tag=⭕ Siri.Bag.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js, requires-body=1, tag=⭕ Siri.Bag.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-request ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, tag=⭕ Siri.Bag.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api2?\.smoot\.apple\.(com|cn)\/bag script-path=https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js, requires-body=1, tag=⭕ Siri.Bag.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
# Siri Suggestions & Look Up Search (iOS/macOS)
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/search script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, tag=🔍 Siri.Search.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/search script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js, requires-body=1, tag=🔍 Siri.Search.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/search script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, tag=🔍 Siri.Search.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/search script-path=https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js, requires-body=1, tag=🔍 Siri.Search.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
# Siri Infomation Card (macOS)
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/card script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, tag=📇 Siri.Card.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/card script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/response.bundle.js, requires-body=1, tag=📇 Siri.Card.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/card script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, tag=📇 Siri.Card.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-response ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/card script-path=https://github.com/NSRingo/Siri/releases/latest/download/response.bundle.js, requires-body=1, tag=📇 Siri.Card.response, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
# Flight Search (iOS/macOS)
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/flight script-path=https://github.com/NSRingo/Siri/releases/download/v4.1.0/request.bundle.js, tag=🛫 Siri.Flight.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]
http-request ^https?:\/\/api(2|-.+)\.smoot\.apple\.(com|cn)\/flight script-path=https://github.com/NSRingo/Siri/releases/latest/download/request.bundle.js, tag=🛫 Siri.Flight.request, argument=[{CountryCode},{Domains},{Functions},{SafariSmartHistory},{LogLevel}]

[MITM]
hostname = api*.smoot.apple.com, api.smoot.apple.cn
Loading

0 comments on commit c2df0fb

Please sign in to comment.