diff --git a/docker-compose.yml b/docker-compose.yml index 14d22cfc49e89e41e3a15acbded9b6be5a617be0..7d939c06eddb1ac60b5f5e314b288ad4cc2d82de 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -16,7 +16,7 @@ services: environment: DATABASE_URL: postgresql://testuser:testuserpass@db:5432/testdb LOG_LEVEL: INFO - STEEMD_URL: '{"default" : "https://api.steemit.com"}' + STEEMD_URL: '{"default" : "https://api.hive.blog"}' links: - db:db ports: diff --git a/docs/api-examples.md b/docs/api-examples.md index 1a2fcdc9783890d35ef2c92068971a5f4b80a6e1..4255e62d95ee331f7e582a5047b65a311b81fd45 100644 --- a/docs/api-examples.md +++ b/docs/api-examples.md @@ -60,9 +60,9 @@ http -j post http://localhost:8080 jsonrpc=2.0 id=1 method=hive.search params:=' # steemd.legacy (deprecated) ``` -http -j post https://api.steemit.com jsonrpc=2.0 id=1 method=call params:='["follow_api","get_follow_count",["test-safari"]]' -http -j post https://api.steemit.com jsonrpc=2.0 id=1 method=call params:='["follow_api","get_followers",["test-safari","", "blog", 5]]' -http -j post https://api.steemit.com jsonrpc=2.0 id=1 method=call params:='["follow_api","get_following",["test-safari","", "ignore", 2]]' +http -j post https://api.hive.blog jsonrpc=2.0 id=1 method=call params:='["follow_api","get_follow_count",["test-safari"]]' +http -j post https://api.hive.blog jsonrpc=2.0 id=1 method=call params:='["follow_api","get_followers",["test-safari","", "blog", 5]]' +http -j post https://api.hive.blog jsonrpc=2.0 id=1 method=call params:='["follow_api","get_following",["test-safari","", "ignore", 2]]' -http -j post https://api.steemit.com jsonrpc=2.0 id=1 method=call params:='["database_api","get_content",["test-safari", "34gfex-december-spam"]]' +http -j post https://api.hive.blog jsonrpc=2.0 id=1 method=call params:='["database_api","get_content",["test-safari", "34gfex-december-spam"]]' ``` diff --git a/hive/conf.py b/hive/conf.py index 54ea10863ac47ac6894c3bd07ff8f3f75277624c..032afd4f2021a372f3e417a6fb7e955cf5cd51d4 100644 --- a/hive/conf.py +++ b/hive/conf.py @@ -32,7 +32,7 @@ class Conf(): # common add('--database-url', env_var='DATABASE_URL', required=False, help='database connection url', default='') - add('--steemd-url', env_var='STEEMD_URL', required=False, help='steemd/jussi endpoint', default='{"default" : "https://api.steemit.com"}') + add('--steemd-url', env_var='STEEMD_URL', required=False, help='steemd/jussi endpoint', default='{"default" : "https://api.hive.blog"}') add('--muted-accounts-url', env_var='MUTED_ACCOUNTS_URL', required=False, help='url to flat list of muted accounts', default='https://raw.githubusercontent.com/hivevectordefense/irredeemables/master/full.txt') # server diff --git a/hive/steem/client.py b/hive/steem/client.py index 265df3c7ee9cb8e24fae1d7968765d84bc391079..f8efb7b3cd03a28ce601a5307ef00d6556a0adb4 100644 --- a/hive/steem/client.py +++ b/hive/steem/client.py @@ -11,7 +11,7 @@ from hive.steem.block.stream import BlockStream class SteemClient: """Handles upstream calls to jussi/steemd, with batching and retrying.""" # dangerous default value of url but it should be fine since we are not writting to it - def __init__(self, url={"default" : 'https://api.steemit.com'}, max_batch=50, max_workers=1): + def __init__(self, url={"default" : 'https://api.hive.blog'}, max_batch=50, max_workers=1): assert url, 'steem-API endpoints undefined' assert "default" in url, "Url should have default endpoint defined" assert max_batch > 0 and max_batch <= 5000 diff --git a/tests/steem/test_steem_client.py b/tests/steem/test_steem_client.py index 88603d42c963ba3df7eab7122ec349784d60223f..d06a850204899039679d66d736423f310e9ee5b0 100644 --- a/tests/steem/test_steem_client.py +++ b/tests/steem/test_steem_client.py @@ -8,7 +8,7 @@ from hive.steem.client import SteemClient @pytest.fixture def client(): - return SteemClient(url='https://api.steemit.com') + return SteemClient(url='https://api.hive.blog') def test_instance(client): assert isinstance(client, SteemClient)