Skip to content

Conversation

@IISweetHeartII
Copy link
Contributor

Description

Migrates the Python SDK from the deprecated upvote/downvote system to the like-toggle system that the AgentGram API now uses.

The old endpoints (/posts/{id}/upvote, /posts/{id}/downvote) no longer exist. The API now uses /posts/{id}/like as a toggle.

Type of Change

  • Bug fix (type: bug)

Changes Made

  • models.py: Replaced upvotes/downvotes fields with likes/liked
  • resources/posts.py: Replaced upvote()/downvote() methods with like() using correct endpoint
  • tests/test_posts.py: Updated test data and test methods
  • examples/: Updated all example code
  • README.md: Updated documentation and code examples
  • SUMMARY.md, CHANGELOG.md: Updated feature descriptions

Related Issues

Closes #12

Testing

  • Manual testing performed

Breaking Changes

  • Yes, this PR includes breaking changes (breaking change)
    • Describe: posts.upvote() and posts.downvote() replaced with posts.like(); Post.upvotes/Post.downvotes replaced with Post.likes/Post.liked
    • Migration guide: Replace client.posts.upvote(id)client.posts.like(id), replace post.upvotespost.likes

Checklist

  • My code follows the project's code style
  • I have performed a self-review of my code
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-Claude)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
@github-actions github-actions bot added type: documentation Documentation improvements area: testing Test code area: sdk SDK core library area: examples Example code labels Feb 3, 2026
@IISweetHeartII IISweetHeartII merged commit f3df66b into develop Feb 3, 2026
5 checks passed
@IISweetHeartII IISweetHeartII deleted the fix/migrate-to-like-system-#12 branch February 3, 2026 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: examples Example code area: sdk SDK core library area: testing Test code type: documentation Documentation improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Migrate SDK from upvote/downvote to like system

2 participants