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

Deprecate API 'getmyoffer' (#7) #5938

Merged
merged 4 commits into from
Jan 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion apitest/docs/api-beta-test-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ $ ./bisq-cli --password=xyz --port=9998 getmyoffers --direction=<BUY|SELL> --cur

To look at a specific offer you created:
```
$ ./bisq-cli --password=xyz --port=9998 getmyoffer --offer-id=<offer-id>
$ ./bisq-cli --password=xyz --port=9998 getoffer --offer-id=<offer-id>
```

### Browsing Available Offers
Expand Down
2 changes: 1 addition & 1 deletion apitest/scripts/bsqswap-simulation.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ sleeptraced 2

# Show Alice's new bsq swap offer.
printdate "Alice looking at her new $DIRECTION $CURRENCY_CODE offer."
CMD="$CLI_BASE --port=$ALICE_PORT getmyoffer --offer-id=$OFFER_ID"
CMD="$CLI_BASE --port=$ALICE_PORT getoffer --offer-id=$OFFER_ID"
printdate "ALICE CLI: $CMD"
OFFER=$($CMD)
exitoncommandalert $?
Expand Down
2 changes: 1 addition & 1 deletion apitest/scripts/limit-order-simulation.sh
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ sleeptraced 3

# Show Alice's new offer.
printdate "ALICE: Looking at her new $DIRECTION $CURRENCY_CODE offer."
CMD="$CLI_BASE --port=$ALICE_PORT getmyoffer --offer-id=$OFFER_ID"
CMD="$CLI_BASE --port=$ALICE_PORT getoffer --offer-id=$OFFER_ID"
printdate "ALICE CLI: $CMD"
OFFER=$($CMD)
exitoncommandalert $?
Expand Down
2 changes: 1 addition & 1 deletion apitest/scripts/rolling-offer-simulation.sh
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ while : ; do

# Show Alice's new offer.
printdate "ALICE $ALICE_ROLE: Looking at her new $DIRECTION $CURRENCY_CODE offer."
CMD="$CLI_BASE --port=$ALICE_PORT getmyoffer --offer-id=$OFFER_ID"
CMD="$CLI_BASE --port=$ALICE_PORT getoffer --offer-id=$OFFER_ID"
printdate "ALICE CLI: $CMD"
OFFER=$($CMD)
exitoncommandalert $?
Expand Down
2 changes: 1 addition & 1 deletion apitest/scripts/trade-simulation.sh
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ sleeptraced 3

# Show Alice's new offer.
printdate "ALICE $ALICE_ROLE: Looking at her new $DIRECTION $CURRENCY_CODE offer."
CMD="$CLI_BASE --port=$ALICE_PORT getmyoffer --offer-id=$OFFER_ID"
CMD="$CLI_BASE --port=$ALICE_PORT getoffer --offer-id=$OFFER_ID"
printdate "ALICE CLI: $CMD"
OFFER=$($CMD)
exitoncommandalert $?
Expand Down
2 changes: 1 addition & 1 deletion apitest/scripts/trade-xmr-simulation.sh
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ sleeptraced 3

# Show Alice's new offer.
printdate "ALICE $ALICE_ROLE: Looking at her new $DIRECTION $CURRENCY_CODE offer."
CMD="$CLI_BASE --port=$ALICE_PORT getmyoffer --offer-id=$OFFER_ID"
CMD="$CLI_BASE --port=$ALICE_PORT getoffer --offer-id=$OFFER_ID"
printdate "ALICE CLI: $CMD"
OFFER=$($CMD)
exitoncommandalert $?
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ private void testGetMyBsqSwapOffer(OfferInfo bsqSwapOffer) {
while (true) {
try {
numFetchAttempts++;
var fetchedBsqSwapOffer = aliceClient.getMyOffer(bsqSwapOffer.getId());
var fetchedBsqSwapOffer = aliceClient.getOffer(bsqSwapOffer.getId());
assertEquals(bsqSwapOffer.getId(), fetchedBsqSwapOffer.getId());
log.debug("Alice found her (my) new bsq swap offer on attempt # {}.", numFetchAttempts);
break;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ public void testCreateBuy1BTCFor20KBSQOffer() {

genBtcBlockAndWaitForOfferPreparation();

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -132,7 +132,7 @@ public void testCreateSell1BTCFor20KBSQOffer() {

genBtcBlockAndWaitForOfferPreparation();

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -179,7 +179,7 @@ public void testCreateBuyBTCWith1To2KBSQOffer() {

genBtcBlockAndWaitForOfferPreparation();

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -226,7 +226,7 @@ public void testCreateSellBTCFor5To10KBSQOffer() {

genBtcBlockAndWaitForOfferPreparation();

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ public void testCreateAUDBTCBuyOfferUsingFixedPrice16000() {
assertEquals("AUD", newOffer.getCounterCurrencyCode());
assertFalse(newOffer.getIsCurrencyForMakerFeeBtc());

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -120,7 +120,7 @@ public void testCreateUSDBTCBuyOfferUsingFixedPrice100001234() {
assertEquals(USD, newOffer.getCounterCurrencyCode());
assertFalse(newOffer.getIsCurrencyForMakerFeeBtc());

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -165,7 +165,7 @@ public void testCreateEURBTCSellOfferUsingFixedPrice95001234() {
assertEquals(EUR, newOffer.getCounterCurrencyCode());
assertFalse(newOffer.getIsCurrencyForMakerFeeBtc());

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public void testCreateUSDBTCBuyOffer5PctPriceMargin() {
assertEquals(USD, newOffer.getCounterCurrencyCode());
assertTrue(newOffer.getIsCurrencyForMakerFeeBtc());

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -143,7 +143,7 @@ public void testCreateNZDBTCBuyOfferMinus2PctPriceMargin() {
assertEquals("NZD", newOffer.getCounterCurrencyCode());
assertTrue(newOffer.getIsCurrencyForMakerFeeBtc());

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -190,7 +190,7 @@ public void testCreateGBPBTCSellOfferMinus1Point5PctPriceMargin() {
assertEquals("GBP", newOffer.getCounterCurrencyCode());
assertTrue(newOffer.getIsCurrencyForMakerFeeBtc());

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -237,7 +237,7 @@ public void testCreateBRLBTCSellOffer6Point55PctPriceMargin() {
assertEquals("BRL", newOffer.getCounterCurrencyCode());
assertTrue(newOffer.getIsCurrencyForMakerFeeBtc());

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -276,7 +276,7 @@ public void testCreateUSDBTCBuyOfferWithTriggerPrice() {
assertTrue(newOffer.getIsMyPendingOffer());

genBtcBlocksThenWait(1, 4000); // give time to add to offer book
newOffer = aliceClient.getMyOffer(newOffer.getId());
newOffer = aliceClient.getOffer(newOffer.getId());
log.debug("OFFER #5:\n{}", toOfferTable.apply(newOffer));
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public void testCreateFixedPriceBuy1BTCFor200KXMROffer() {

genBtcBlockAndWaitForOfferPreparation();

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -135,7 +135,7 @@ public void testCreateFixedPriceSell1BTCFor200KXMROffer() {

genBtcBlockAndWaitForOfferPreparation();

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down Expand Up @@ -188,7 +188,7 @@ public void testCreatePriceMarginBasedBuy1BTCOfferWithTriggerPrice() {

genBtcBlockAndWaitForOfferPreparation();

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
log.debug("Available Sell XMR (Buy BTC) offer:\n{}", toOfferTable.apply(newOffer));
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
Expand Down Expand Up @@ -240,7 +240,7 @@ public void testCreatePriceMarginBasedSell1BTCOffer() {

genBtcBlockAndWaitForOfferPreparation();

newOffer = aliceClient.getMyOffer(newOfferId);
newOffer = aliceClient.getOffer(newOfferId);
assertTrue(newOffer.getIsMyOffer());
assertFalse(newOffer.getIsMyPendingOffer());
assertEquals(newOfferId, newOffer.getId());
Expand Down
Loading