-
-
Notifications
You must be signed in to change notification settings - Fork 7.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add PlayStation Network Documentation #36520
base: next
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for home-assistant-docs ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
📝 WalkthroughWalkthroughThe pull request introduces a new integration for PlayStation Network in Home Assistant, enabling users to track and display information about their currently playing games. The integration allows connection to PlayStation Network accounts using an NPSSO token, creating media player entities for PlayStation 4 and PlayStation 5 consoles. It supports retrieving game information with periodic updates every 30 seconds, while maintaining a request rate limit of 300 calls per 15 minutes. Changes
Sequence DiagramsequenceDiagram
participant User
participant HA as Home Assistant
participant PSN as PlayStation Network
User->>HA: Configure PSN Integration
User->>HA: Provide NPSSO Token
HA->>PSN: Authenticate & Request Game Data
PSN-->>HA: Return Game Information
HA->>HA: Create Media Player Entities
HA->>PSN: Periodic Data Refresh (30s)
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (2)
source/_integrations/playstation_network.markdown (2)
15-18
: Consider adding developer documentation linksThe related links section could be enhanced by including links to:
- PlayStation Network API documentation
- PlayStation Developer Portal
- The integration's source code in Home Assistant
This would help users and developers better understand the integration's capabilities.
24-24
: Improve writing clarityConsider revising the sentence to be more concise:
-PlayStation Network (PSN) is a digital media entertainment service provided by [Sony Interactive Entertainment](https://en.wikipedia.org/wiki/Sony_Interactive_Entertainment). It allows users to enjoy a variety of gaming-related services such as purchasing games, downloading content, and connecting with other players. +PlayStation Network (PSN) is a digital media entertainment service provided by [Sony Interactive Entertainment](https://en.wikipedia.org/wiki/Sony_Interactive_Entertainment). It enables users to purchase games, download content, and connect with other players.🧰 Tools
🪛 LanguageTool
[style] ~24-~24: The phrase “a variety of” may be wordy. To make your writing clearer, consider replacing it.
Context: ...ntertainment). It allows users to enjoy a variety of gaming-related services such as purchas...(A_VARIETY_OF)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
source/_integrations/playstation_network.markdown
(1 hunks)
🧰 Additional context used
🪛 LanguageTool
source/_integrations/playstation_network.markdown
[style] ~24-~24: The phrase “a variety of” may be wordy. To make your writing clearer, consider replacing it.
Context: ...ntertainment). It allows users to enjoy a variety of gaming-related services such as purchas...
(A_VARIETY_OF)
🔇 Additional comments (2)
source/_integrations/playstation_network.markdown (2)
52-52
: Verify rate limit calculations and add update details
The integration makes 3 requests every 30 seconds:
- 6 requests per minute
- 360 requests per hour
- 90 requests per 15 minutes
While this is within the 300 requests/15 minutes limit, please:
- Specify what data is retrieved in each request
- Explain the retry strategy if rate limits are hit
- Consider implementing exponential backoff for failed requests
Also applies to: 58-58
6-6
: Verify the release version
The release version 2025.1
seems unusually far in the future. Please verify if this is the intended version or if it should be adjusted to a nearer release.
✅ Verification successful
Let me verify the release version by checking other integration documentation files and Home Assistant's release patterns.
Let me try a different approach to check the documentation files and release patterns.
Based on the search results, I can see several integrations with release version 2025.1, including:
- watergate
- powerfox
- playstation_network
- slide_local
- ohme
- ituran
- eheimdigital
- cookidoo
This indicates that 2025.1 is a valid future release version used for upcoming integrations. Since this is a new integration (PlayStation Network) being added, setting the release version to 2025.1 appears to be intentional and follows the pattern used by other new integrations.
Release version 2025.1 is appropriate for this new integration
The version follows the established pattern for new integrations being added to Home Assistant, as evidenced by several other new integrations using the same future release version.
🏁 Scripts executed
The following scripts were executed for the analysis:
Error: No shell scripts found
Script:
#!/bin/bash
# Check recent integration documentation files for their release versions
rg "ha_release:" "source/_integrations/*.markdown" -A 1
# Also check the current version in manifest files
fd manifest.json --exec cat {} \; | jq -r '. | select(.version != null) | .version'
Length of output: 216
Script:
#!/bin/bash
# Check recent integration documentation files for their release versions
rg "ha_release:" source/ -A 1
# List documentation files to verify path structure
fd . source/ -e markdown
Length of output: 66780
## Prerequisites for PlayStation Network integration | ||
|
||
- To set up the PlayStation Network integration, you must first have an active PlayStation Network account. You can register for an account at the [Official PlayStation® Site](https://playstation.com/). | ||
- During the setup process in Home Assistant, you will be asked to provide your NPSSO token. You will need to be logged into [playstation.com](https://playstation.com/) to access the token in your browser. You will find a link to retrieve the token in the config flow. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Add specific instructions for NPSSO token retrieval
The documentation mentions that users will find a link to retrieve the token in the config flow, but it would be helpful to include:
- Direct steps to obtain the NPSSO token
- Screenshots or a visual guide
- Troubleshooting tips for common token retrieval issues
This would improve the user experience during setup.
Proposed change
This change contains the documentation to accompany the new PlayStation Network integration found on PR#133901. It has followed the quality scale recommendations and attempts to cover all bronze level tasks.
Type of change
current
branch).current
branch).next
branch).next
branch).Additional information
Checklist
current
branch.next
branch.Summary by CodeRabbit
New Features
Documentation