Skip to content
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

How to connect to testnet ? #19

Open
Zeppe79 opened this issue Nov 27, 2023 · 3 comments
Open

How to connect to testnet ? #19

Zeppe79 opened this issue Nov 27, 2023 · 3 comments

Comments

@Zeppe79
Copy link

Zeppe79 commented Nov 27, 2023

Hi, I'm trying to connect to testnet api but it doesn't work. Also I've tried to setOptions testnet => true, but no success

$bybit = new BybitLinear($user_api->api_key,$user_api->api_secret,'https://api.bybit.com'); $bybit->setOptions( ['testnet' => true] );

Do you have any suggestion ?

Thanks

@zhouaini528
Copy link
Owner

$bybit=new BybitLinear($key,$secret,'https://apt-testnet.bybit.com');

I found out that Bybit already has a version v5 and I may need to update it

@Zeppe79
Copy link
Author

Zeppe79 commented Nov 29, 2023 via email

@zhouaini528
Copy link
Owner

Hi yes, some user on github already deployed a v5 version Thanks for your support Il Mer 29 Nov 2023, 07:17 lin @.> ha scritto:

$bybit=new BybitLinear($key,$secret,'https://apt-testnet.bybit.com'); I found out that Bybit already has a version v5 and I may need to update it — Reply to this email directly, view it on GitHub <#19 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD5JQTF7Z5TENQP54LC6FZ3YG3HPJAVCNFSM6AAAAAA74UPWHOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMZRGI4DMMZVG4 . You are receiving this because you authored the thread.Message ID: @.
>

I've finished the V5 version. However, I can't verify my identity on the exchange, and I can't test the real order. You can try to see if it's correct.

https://github.com/zhouaini528/bybit-php/blob/master/tests/v5/order.php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants